Click here to monitor SSC
SQLServerCentral is supported by Red Gate Software Ltd.
 
Log in  ::  Register  ::  Not logged in
 
 
 
        
Home       Members    Calendar    Who's On


Add to briefcase «««1234»»

Don't forget this date. Expand / Collapse
Author
Message
Posted Friday, April 02, 2010 11:09 AM


SSC-Insane

SSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-Insane

Group: General Forum Members
Last Login: Today @ 10:05 AM
Points: 20,458, Visits: 14,085
Voitek (4/2/2010)
I did a cast(0 as datetime), but then I thought hmm. can negatives be converted to datetime? I picked 64000, but that failed, so then I went incrementally to -53690 beyond which the cast fails.
I don't think the QOD is misleading. The oldest date you can store is -53690, which is 1-1-1753.


Nice information. Thanks for providing it.




Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server


SQL RNNR

Posting Performance Based Questions - Gail Shaw
Posting Data Etiquette - Jeff Moden
Hidden RBAR - Jeff Moden
VLFs and the Tran Log - Kimberly Tripp
Post #895849
Posted Friday, April 02, 2010 11:24 AM


SSChampion

SSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampionSSChampion

Group: General Forum Members
Last Login: Today @ 5:59 AM
Points: 11,168, Visits: 10,931
CirquedeSQLeil (4/2/2010)
Surprised it hasn't happened yet.

vk-kirov covered it!




Paul White
SQL Server MVP
SQLblog.com
@SQL_Kiwi
Post #895864
Posted Friday, April 02, 2010 11:33 AM


SSC-Insane

SSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-Insane

Group: General Forum Members
Last Login: Today @ 10:05 AM
Points: 20,458, Visits: 14,085
Paul White NZ (4/2/2010)
CirquedeSQLeil (4/2/2010)
Surprised it hasn't happened yet.

vk-kirov covered it!


I found that comment funny.




Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server


SQL RNNR

Posting Performance Based Questions - Gail Shaw
Posting Data Etiquette - Jeff Moden
Hidden RBAR - Jeff Moden
VLFs and the Tran Log - Kimberly Tripp
Post #895876
Posted Friday, April 02, 2010 12:28 PM


SSC-Insane

SSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-Insane

Group: General Forum Members
Last Login: Today @ 6:59 AM
Points: 22,492, Visits: 30,186
I found this one fairly easy. Good discussion, which adds to question.



Lynn Pettis

For better assistance in answering your questions, click here
For tips to get better help with Performance Problems, click here
For Running Totals and its variations, click here or when working with partitioned tables
For more about Tally Tables, click here
For more about Cross Tabs and Pivots, click here and here
Managing Transaction Logs

SQL Musings from the Desert Fountain Valley SQL (My Mirror Blog)
Post #895923
Posted Monday, April 05, 2010 2:30 AM
SSCertifiable

SSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiableSSCertifiable

Group: General Forum Members
Last Login: Thursday, March 20, 2014 7:32 AM
Points: 5,191, Visits: 1,368
I didn't knew it.. Great one to know...


Post #896579
Posted Monday, April 05, 2010 9:48 AM
SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Tuesday, April 01, 2014 2:53 PM
Points: 1,676, Visits: 1,744
This is a very interesting question, thank you Carla. I knew that 1753-01-01 was selected as the first available date, but had no clue why the SQL Server team chose it. The number -53690 does not appear to be of any significance, so I learned something new today.

Oleg
Post #896801
Posted Monday, April 05, 2010 11:56 PM
Forum Newbie

Forum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum NewbieForum Newbie

Group: General Forum Members
Last Login: Thursday, January 27, 2011 2:44 AM
Points: 3, Visits: 7
same with me ...whenever i selects date columns it shows same..
Post #897325
Posted Tuesday, April 06, 2010 9:47 AM


SSC-Insane

SSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-InsaneSSC-Insane

Group: General Forum Members
Last Login: Today @ 10:05 AM
Points: 20,458, Visits: 14,085
Lynn Pettis (4/2/2010)
I found this one fairly easy. Good discussion, which adds to question.



I have to admit, I did not find this one as easy. I did have to do some checking and research.




Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server


SQL RNNR

Posting Performance Based Questions - Gail Shaw
Posting Data Etiquette - Jeff Moden
Hidden RBAR - Jeff Moden
VLFs and the Tran Log - Kimberly Tripp
Post #897658
Posted Thursday, April 08, 2010 8:20 AM
SSC Eights!

SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!SSC Eights!

Group: General Forum Members
Last Login: 2 days ago @ 8:19 AM
Points: 940, Visits: 1,281
Any idea what the latest date is? I got as far as 500,000 days into the future before i gave up, I doubt i'd have much use for this unless i'm using DBCC timewarp though
Post #899606
Posted Thursday, April 08, 2010 8:39 AM
SSCommitted

SSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommittedSSCommitted

Group: General Forum Members
Last Login: Tuesday, April 15, 2014 3:30 PM
Points: 1,525, Visits: 1,833
From MS SQL documentation:
datetime: January 1, 1753, through December 31, 9999
smalldatetime: January 1, 1900, through June 6, 2079

Note:
datetime is stored as two 4-byte integers for days from 1/1/1900 and milliseconds since midnight.
smalldatetime is stored as two 2-byte integers for days from 1/1/1900 and minutes since midnight.
Post #899633
« Prev Topic | Next Topic »

Add to briefcase «««1234»»

Permissions Expand / Collapse