Posts Topics Forums Images
Search videos from message boards Videos Search messages from microblogs Microblogs Search messages from imdb.com Imdb Search messages from yuku.com Yuku Search messages from lefora.com (free forums) Lefora
My account: Login | Sign Up
Loading... 

Thread: SQL 2005 database & date formats...

Started 1 month, 3 weeks ago by leeshadmi
Hi, My dev computer set to be as USA date format ex: MM/DD/YYYY. All works for me and for other coputer in this format but when i try my application + it's database on other computer that have the UK format ex: DD/MM/YYYY it not working and i cant save my data to the datbase. My code not related to this format or other so i guess my problems is with my database fields settings. What...
Site: CodeGuru Forums - A Developer.com Community for C++, C#, VB, Java and .NET Solutions  CodeGuru Forums - A Developer.com Community for C++, C#, VB, Java and .NET Solutions - site profile
Forum: Database  Database - forum profile
Total authors: 3 authors
Total thread posts: 6 posts
Thread activity: no new posts during last week
Domain info for: codeguru.com

Other posts in this thread:

VictorN replied 1 month, 3 weeks ago
The "standard" (or locale independent) SQL format for date/time is: 'YYYY-mm-dd HH:MM:SS'

leeshadmi replied 1 month, 3 weeks ago
How can i set it i use SQL 2005 Express Edition? My database is attached.

VictorN replied 1 month, 3 weeks ago
UPDATE MyTable SET CurrentTime_for_Zone_UTC_plus_3 = '2009-10-29 09:27:50'

leeshadmi replied 1 month, 3 weeks ago
ok ,thanks i will try this

Alsvha replied 1 month, 3 weeks ago
While the ISO format that VictorN gives always should work, you can also define it in cast/convert functions for when you're not writing it manually. Take a look at this page from msdn: http://msdn.microsoft.com/en-us/library/ms187928.a spx

 

Top contributing authors

Name
Posts
leeshadmi
3
user's latest post:
SQL 2005 database & date...
Published (2009-10-29 03:54:00)
ok ,thanks i will try this
VictorN
2
user's latest post:
SQL 2005 database & date...
Published (2009-10-29 03:28:00)
UPDATE MyTable SET CurrentTime_for_Zone_UTC_plus_3 = '2009-10-29 09:27:50'
Alsvha
1
user's latest post:
SQL 2005 database & date...
Published (2009-10-29 06:03:00)
While the ISO format that VictorN gives always should work, you can also define it in cast/convert functions for when you're not writing it manually. Take a look at this page from msdn: http://msdn.microsoft.com/en-us/library/ms187928.aspx

Related threads on "CodeGuru Forums - A Developer.com Community for C++, C#, VB, Java and .NET Solutions":

Related threads on other sites:

Thread profile page for "SQL 2005 database & date formats..." on http://www.codeguru.com. This report page is a snippet summary view from a single thread "SQL 2005 database & date formats...", located on the Message Board at http://www.codeguru.com. This thread profile page shows the thread statistics for: Total Authors, Total Thread Posts, and Thread Activity