-----------------------------------------------------------

New Message on BDOTNET

-----------------------------------------------------------
From: Shailender
Message 2 in Discussion


 
Hi,
 
By Default 
SQL is storing the Date in MM/DD/YYYY format. If you passing the date in 
dd/mm/yyyy format in sql query it will give error. 
what you 
can do  is you can get entered the date in dd/mm/yyyy format from client 
and then change it to mm/dd/yyyy and then store it to sql server. Or if you are 
getting the date through date() function you can use Session.LCID = 1033 to make 
sure that the date from the date() is passing in mm/dd/yyyy. 

 
At the time 
of showing the date to user use formatdatetime() function.

Shailender 
Singh 
 

DATE SETTINGS 
IN SQL SERVER & IIS - Need Solution



  
  
    Reply

    
      
        
        
           
          Reply to Sender   Recommend 
          Message 1 in Discussion 
          
  
    
      
        
        
          From: BalajiKrishnan 
        
          

            I want to change the default date formate in sql server and 
            IIS.
If I change in Regional setting, it is not reflecting in 
            this.

In regional setting it shows dd/mm/yyyy. in command 
            prompt if is say date it
show in this fomate(27/04/2004). It is 
            correct.

In sql server if i save select getdate() - it shows 
            (2004-04-27
08:59:01.667) - yyyy-mm-dd

In IIS - i written 
            one asp page to get the time - it shows 4/27/2004.

What I 
            feel was, SQL server and IIS is not taking date format from regional 
            setting.

I want to change the date format to dd/mm/yyyy or 
            dd/mmm/yyyy in sql server
and IIS.

            How can i do 
this
View other groups in this 
category. 




-----------------------------------------------------------

To stop getting this e-mail, or change how often it arrives, go to your E-mail 
Settings.
http://groups.msn.com/bdotnet/_emailsettings.msnw

Need help? If you've forgotten your password, please go to Passport Member Services.
http://groups.msn.com/_passportredir.msnw?ppmprop=help

For other questions or feedback, go to our Contact Us page.
http://groups.msn.com/contact

If you do not want to receive future e-mail from this MSN group, or if you received 
this message by mistake, please click the "Remove" link below. On the pre-addressed 
e-mail message that opens, simply click "Send". Your e-mail address will be deleted 
from this group's mailing list.
mailto:[EMAIL PROTECTED]

Reply via email to