dbTalk Databases Forums  

Error on datetime fields

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Error on datetime fields in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Andrew Robinson
 
Posts: n/a

Default Error on datetime fields - 04-15-2004 , 03:25 PM






I have created a DTS package, and get errors on some datetime fields
when I attempt to run it. The source data is in the 'yyyymmdd' format.
The destination field is datetime, and the transformation type is
datetime, with the format of 'MM/dd/yyyy'. Some of these data fields
work perfectly, but some give me the error message:

Insert error, Col41('due_date',DBTYPE_DBTIMESTAMP), status 6: data
overflow
Invalid character value for cast specification

As I said, the destination field's datatype is datetime, NOT
timestamp. This only happens on some of the date fields. Has anyone
else encountered anything similar? Thanks in advance for your help.

Reply With Quote
  #2  
Old   
Sue Hoegemeier
 
Posts: n/a

Default Re: Error on datetime fields - 04-15-2004 , 03:57 PM






The valid date range for SQL Server's datetime data type is
1/1/1753 through 12/31/9999
It could be that the source data has a date that falls out
of this range.

-Sue

On 15 Apr 2004 13:25:25 -0700, arx (AT) miamidade (DOT) gov (Andrew
Robinson) wrote:

Quote:
I have created a DTS package, and get errors on some datetime fields
when I attempt to run it. The source data is in the 'yyyymmdd' format.
The destination field is datetime, and the transformation type is
datetime, with the format of 'MM/dd/yyyy'. Some of these data fields
work perfectly, but some give me the error message:

Insert error, Col41('due_date',DBTYPE_DBTIMESTAMP), status 6: data
overflow
Invalid character value for cast specification

As I said, the destination field's datatype is datetime, NOT
timestamp. This only happens on some of the date fields. Has anyone
else encountered anything similar? Thanks in advance for your help.


Reply With Quote
  #3  
Old   
Allan Mitchell
 
Posts: n/a

Default Re: Error on datetime fields - 04-15-2004 , 04:15 PM



DBTYPE_TIMESTAMP is an OLEDB datatype and maps to the SQL Server datetime
datatype
DBTYPE_BYTES maps to timestamp.



--
--

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org


"Andrew Robinson" <arx (AT) miamidade (DOT) gov> wrote

Quote:
I have created a DTS package, and get errors on some datetime fields
when I attempt to run it. The source data is in the 'yyyymmdd' format.
The destination field is datetime, and the transformation type is
datetime, with the format of 'MM/dd/yyyy'. Some of these data fields
work perfectly, but some give me the error message:

Insert error, Col41('due_date',DBTYPE_DBTIMESTAMP), status 6: data
overflow
Invalid character value for cast specification

As I said, the destination field's datatype is datetime, NOT
timestamp. This only happens on some of the date fields. Has anyone
else encountered anything similar? Thanks in advance for your help.



Reply With Quote
  #4  
Old   
Andrew Robinson
 
Posts: n/a

Default Re: Error on datetime fields - 04-15-2004 , 04:21 PM



All of the dates are in the range 1991-present. Some values are null,
but the 'Allow Nulls' option in the table design is turned on.



*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.