Home

date data type to a datetime data type resulted in an out-of-range value

%3CLINGO-SUB%20id%3D%22lingo-sub-1104056%22%20slang%3D%22en-US%22%3Edate%20data%20type%20to%20a%20datetime%20data%20type%20resulted%20in%20an%20out-of-range%20value%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-1104056%22%20slang%3D%22en-US%22%3E%3CP%3EI've%20a%203rd%20party%20reporting%20software%20using%20SQL%20as%20the%20database.%26nbsp%3B%20During%20ETL%2C%20I%20saw%20this%20error%3A%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E%22System.Exception%3A%20%22The%20statement%20has%20been%20terminated.%22.%20Description%3A%20The%20conversion%20of%20a%20date%20data%20type%20to%20a%20datetime%20data%20type%20resulted%20in%20an%20out-of-range%20value.%22%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EIs%20there%20any%20adjustment%20require%20at%20SQL%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-1104056%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EIntegration%20Services%3C%2FLINGO-LABEL%3E%3CLINGO-LABEL%3EReporting%20Services%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
Highlighted
James Lau
Occasional Contributor

I've a 3rd party reporting software using SQL as the database.  During ETL, I saw this error:

 

"System.Exception: "The statement has been terminated.". Description: The conversion of a date data type to a datetime data type resulted in an out-of-range value."

 

Is there any adjustment require at SQL?

1 Reply

@James Lau 

 

I suggest you can :

1. compare each fields’ data types between reports and physical tables to find out which field is the root cause.

2. Drop the convent function in report and check out the original value. Perhaps the value is not a validated date time.

3. Revise the report to bypass that invalidated value or fix that value just temporarily, ex. display it as String type for that field. If you would like fix it in database, you can investigate the reason of that entry first. Please inform relevant member(s) once you decide to fix it in database.

 

Regards, 

Sten