Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 Site Related Forums
 Article Discussion
 Article: Timestamps vs Datetime data types

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2000-11-19 : 10:25:43
saka writes "Hi there, gurus, I have a really tough question regarding an sql query involving dates. I have a table (links) containing a column with dates (gdate). When I run the following statement I won't get any records at all, just the fields:

SELECT * FROM links WHERE gdate = 2000-11-05

N.B. The table do have a record with the above date and it doesn't work with another date either. The field type is dbtimestamp. Greetings from Sweden"

Article Link.

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2007-03-20 : 11:01:53
It will actually get you all records for the date '1905-06-08 00:00:00.000', it you execute it.


Peter Larsson
Helsingborg, Sweden
Go to Top of Page

Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)

7020 Posts

Posted - 2007-03-20 : 12:11:37
quote:
Originally posted by Peso

It will actually get you all records for the date '1905-06-08 00:00:00.000', it you execute it.


Peter Larsson
Helsingborg, Sweden



Are there not enough current lost yaks? Do you have to dig them up from 6 years ago?





CODO ERGO SUM
Go to Top of Page
   

- Advertisement -