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!

Text Qualifier not working

Status
Not open for further replies.

Cpreston

MIS
Mar 4, 2015
972
GB
Hi

I am importing a csv file with rows like below. This is then being imported into a SQL table. If I pout a text qualifier in of " to make the preview look perfect the package will not run.
If I leave the text qualifier blank then it runs. However it then corrupts the import an puts information into the incorrect columns.

Any ideas how I can solve this please. I need to use " in the text qualifier but then it fails on the flat file source. THanks


1437,06/07/2016 00:00,"Island Mist,Gravel Path",,Name1,,56 Eastcote Road,,Welling,,DA16 2ST,email1.com,,No
1436,06/07/2016 00:00,"Tiki Torch,Spiced Rum",,Name2,,56 Eastcote Road,,Welling,,DA16 2ST,email2,,No
1435,06/07/2016 00:00,Torino Brown,,Name3,The Ashbournes,"High Eggborough Lane, Eggborough",Goole,North Yorkshire,DN14 0PS,email3.com,7885818442,Yes
 
Hi

I will get the message details to you. It fails on the txt part and goes red but I cannot remember the information of the error it gived. I am away for a week now but will update ths when I get back to work.

Thanks for your replys
 
Hi

If your error is: [Flat File Source [2]] Error: Cannot open the datafile "...csv".

Try closing the CSV file and rerun the Task


 
Hi

Sorry for the late reply, I am getting quite as large error messages and no matter what text qualifier I put in I cannot get passed the flat file source. I have checked the CSV file and all the columns look ok and have the right data in. Any ideas please

SSIS package "Allsamples.dtsx" starting.
Information: 0x4004300A at Data Flow Task, SSIS.Pipeline: Validation phase is beginning.
Information: 0x4004300A at Data Flow Task, SSIS.Pipeline: Validation phase is beginning.
Warning: 0x80049304 at Data Flow Task, SSIS.Pipeline: Warning: Could not open global shared memory to communicate with performance DLL; data flow performance counters are not available. To resolve, run this package as an administrator, or on the system's console.
Information: 0x40043006 at Data Flow Task, SSIS.Pipeline: Prepare for Execute phase is beginning.
Information: 0x40043007 at Data Flow Task, SSIS.Pipeline: Pre-Execute phase is beginning.
Information: 0x402090DC at Data Flow Task, Flat File Source [770]: The processing of file "\\its4000\arborforestproducts\Trex\database 2013\contacts.csv" has started.
Information: 0x4004300C at Data Flow Task, SSIS.Pipeline: Execute phase is beginning.
Error: 0xC02020A1 at Data Flow Task, Flat File Source [770]: Data conversion failed. The data conversion for column ""Samples"" returned status value 4 and status text "Text was truncated or one or more characters had no match in the target code page.".
Error: 0xC020902A at Data Flow Task, Flat File Source [770]: The "output column ""Samples"" (787)" failed because truncation occurred, and the truncation row disposition on "output column ""Samples"" (787)" specifies failure on truncation. A truncation error occurred on the specified object of the specified component.
Error: 0xC0202092 at Data Flow Task, Flat File Source [770]: An error occurred while processing file "\\its4000\arborforestproducts\Trex\database 2013\contacts.csv" on data row 10.
Error: 0xC0047038 at Data Flow Task, SSIS.Pipeline: SSIS Error Code DTS_E_PRIMEOUTPUTFAILED. The PrimeOutput method on component "Flat File Source" (770) 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.
Information: 0x40043008 at Data Flow Task, SSIS.Pipeline: Post Execute phase is beginning.
Information: 0x402090DD at Data Flow Task, Flat File Source [770]: The processing of file "\\its4000\arborforestproducts\Trex\database 2013\contacts.csv" has ended.
Information: 0x402090DF at Data Flow Task, OLE DB Destination [913]: The final commit for the data insertion in "component "OLE DB Destination" (913)" has started.
Information: 0x402090E0 at Data Flow Task, OLE DB Destination [913]: The final commit for the data insertion in "component "OLE DB Destination" (913)" has ended.
Information: 0x4004300B at Data Flow Task, SSIS.Pipeline: "component "OLE DB Destination" (913)" wrote 0 rows.
Information: 0x40043009 at Data Flow Task, SSIS.Pipeline: Cleanup phase is beginning.
Task failed: Data Flow Task
Warning: 0x80019002 at Allsamples: SSIS Warning Code DTS_W_MAXIMUMERRORCOUNTREACHED. The Execution method succeeded, but the number of errors raised (4) reached the maximum allowed (1); resulting in failure. This occurs when the number of errors reaches the number specified in MaximumErrorCount. Change the MaximumErrorCount or fix the errors.
SSIS package "Allsamples.dtsx" finished: Failure.
 
Hi

Please ignore the last post I have managed to get it going, lots of messing about but have got it working now.
I practically had to rebuild it all so cannot say exactly what got it working.

Thanks for the replies
 
Glad you got it working - as an after thought, was the successful import the same file or a different file? Wondering if it could have been a specific data issue to cause the failure.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top