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
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 problem with date type column

Author  Topic 

nsrao_1975
Starting Member

13 Posts

Posted - 2004-03-05 : 06:57:31
hi,

when i am trying to convert a date column in source table (foxpro 2.5a) which is having blank value { / / } it is converted as
1899-12-30 00:00:00.000 in sqlserver table..how can i keep a null value in destination table for all such cases..

can any guru help me out here..
thanks in advance

ns rao

raymondpeacock
Constraint Violating Yak Guru

367 Posts

Posted - 2004-03-05 : 07:03:37
It depends on how you are importing the data. The easiest solution may be to process the records imported to set the datetime column to null when they have that value. Processing the rowset to avoid the automatic conversion will require coding at some point to trap the transfer and use a CASE statement or something similar to check the source value before writing it to the sql server table.


Raymond
Go to Top of Page
   

- Advertisement -