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.
| Author |
Topic |
|
soorajtnpki
Posting Yak Master
231 Posts |
Posted - 2008-12-04 : 01:10:31
|
| hi all, how do we manage dates before year 1753 ? for example date like 03-Nov-1526 tanx in advance..... |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2008-12-04 : 01:23:34
|
It depends on what you will do with the dates later, how you will use them.If they are for presentation issues only, leave them as varchar.If you want to search and things, store them as three separate columns; yyyy, mm and dd.Or install SQL Server 2008 which can handle dates back to year 1. E 12°55'05.63"N 56°04'39.26" |
 |
|
|
soorajtnpki
Posting Yak Master
231 Posts |
Posted - 2008-12-04 : 01:26:34
|
| ok tanx peso.. but is there any problems using dates column as varchar for those particular dates? |
 |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2008-12-04 : 01:28:34
|
It depends on what you will do with the dates later, how you will use them. E 12°55'05.63"N 56°04'39.26" |
 |
|
|
soorajtnpki
Posting Yak Master
231 Posts |
Posted - 2008-12-04 : 01:35:52
|
| ok so we can't convert this varchar date column to datetime for using other datefunctions. am i right ? |
 |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2008-12-04 : 01:37:33
|
Yes you are right.You will have to build your own DATEDIFF/DATEADD functions. Or install SQL Server 2008. E 12°55'05.63"N 56°04'39.26" |
 |
|
|
soorajtnpki
Posting Yak Master
231 Posts |
Posted - 2008-12-04 : 01:44:37
|
| ok very thanks peso |
 |
|
|
jholovacs
Posting Yak Master
163 Posts |
Posted - 2008-12-04 : 10:09:20
|
You could make your own data type, to include a unix-style epoch. That would also imply making your own datetime functions too though, which could get ugly, quick. SELECT TOP 1 w.[name]FROM dbo.women wINNER JOIN dbo.inlaws i ON i.inlaw_id = w.parent_idWHERE i.net_worth > 10000000 AND i.status IN ('dead', 'dying') AND w.husband_id IS NULLORDER BY w.hotness_factor DESC |
 |
|
|
|
|
|