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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

how to convert DBTYPE_STR to DBTYPE_TIMESTAMP 1

Status
Not open for further replies.

Jeet2004

MIS
Jun 29, 2005
96
US
I have a flat file and the data needs to be imported to a sql server. I did the dts package for it. Now the problem is out of 8 columns 3 are datetime whereas in excel everything is varchar.
So only for one column out of three(with datetime datatype) the job fails and give the error

Error Description: The number of failing rows exceeds the maximum specified. TransformCopy'DTSTransformation_5' conversion Error: Conversion invalid for datatypes on column pair 1(source column 'columnname'(DBTYPE_STR), destination column 'hire_date'(DBTYPE_DBTIMESTAMP))


Can anyone help me to get rid of this error
Thanks.
note: i tried using cdate in activex script still it doesnt work

Thanks
 
You can use CAST or CONVERT.

Dr. Sql
goEdeveloper@yahoo.com
Good Luck.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top