Link to home
Start Free TrialLog in
Avatar of oldtedt
oldtedt

asked on

error importing csv to sql

Hi.

I am trying to import a csv into SQL 2008 and i get the following error:

Executing (Error)
Messages
Error 0xc02020a1: Data Flow Task 1: Data conversion failed. The data conversion for column "Mailing Street" returned status value 4 and status text "Text was truncated or one or more characters had no match in the target code page.".
 (SQL Server Import and Export Wizard)
 
Error 0xc020902a: Data Flow Task 1: The "output column "Mailing Street" (98)" failed because truncation occurred, and the truncation row disposition on "output column "Mailing Street" (98)" specifies failure on truncation. A truncation error occurred on the specified object of the specified component.
 (SQL Server Import and Export Wizard)
 
Error 0xc0202092: Data Flow Task 1: An error occurred while processing file "C:\Users\tanvi\Documents\Fusion\database\salesforce\report1282048903904_test.csv" on data row 3.
 (SQL Server Import and Export Wizard)
 
Error 0xc0047038: Data Flow Task 1: SSIS Error Code DTS_E_PRIMEOUTPUTFAILED.  The PrimeOutput method on component "Source - report1282048903904_test_csv" (1) returned error code 0xC0202092.  The component returned a failure code when the pipeline engine called PrimeOutput(). The meaning of the failure code is defined by the component, but the error is fatal and the pipeline stopped executing.  There may be error messages posted before this with more information about the failure.
 (SQL Server Import and Export Wizard)

please help as i have no idea what this means.
ASKER CERTIFIED SOLUTION
Avatar of vdr1620
vdr1620
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of oldtedt
oldtedt

ASKER

Thanks for that. it was a trucation problem, difference in the size of source and destinatation. this error occured for various other fields as well since sql import takes a default size of 50. I just changed all sizes to 1000. Also the surprising bit was i got the same error for a date value in source file. i had to increase that to 1000 as well!