Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Error during DTS Import

Status
Not open for further replies.

newtechy

Programmer
Sep 23, 2002
22
US
I am trying to import a delimited text file into a Sql Server table. The text file is about 40k. During the DTS import, I am getting an error during the transformation process indicating that a text file field (which has nulls in it) can not be transformed into a database table field. I've defined the database table field as a date/time field which allows nulls. I've assigned a default value of getdate(). The import works when importing small text files (say about 10k) , but when I'm importing the 40k file, I am getting the error. Please advise
 
newtechy,

Have you tried a test import into a table of varchar datatypes to see if it's the datatype that may be causing the error.
If this runs OK, then you could simply import into a temp table and then transform the data from there, as errors are easier to sort through once the data is server side.

Logicalman
 
Ref "The import works when importing small text files (say about 10k) , but when I'm importing the 40k file, I am getting the error. "

This doesn't make sense. Data is data, it shouldn't matter how big the file is. I would double check to make sure you are looking at the right row that is giving you the error, then try to import a file containing just that one row.

Keep in mind that is a difference between Null data and an empty string, or spaces. (Are you using text qualifiers?)
If you are importing into a date format, the orginating data must be truly null -> blank spaces or empty strings ('' or "")will not work.
 
Thanks to both of for your help. I found what the problem was and it was data related...Thanks again
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top