Thursday, March 29, 2012

Embedded text qualifiers

We have text files that are comma delimited, use double quotes as text qualifiers and sometimes have embedded double quotes. The embedded double quotes are escaped with an additional double quote like: below.

"123","product q"

"124","product ""a"""

DTS 2000 had no problem with this- it correctly parsed the files. The 2005 SSIS file connection manager correctly parses this in preview mode. But when the task is executed the task fails with the message "The column delimiter for column X was not found".

What is the recommended approach for this - we have alot of files in this format.

thanks

Please search the forums.

This should get you started: (in a sense, it's not going to be easy) http://forums.microsoft.com/MSDN/ShowPost.aspx?PostID=80634&SiteID=1|||I've had to do this as the other post with a script component. I import the whole row as a single column, then run via a regular expression a split command and then use replace function as well. Thats the best solution I have come across to your issue.|||Another workaround that I used successfully was to simply change the source file format. I changed it to |~| delimeter and no text qualifier. In addition I configured the SSIS source file connection manager to recognize the |~| as the delimiter and did not set the text qualifer option. In the end, it proved less painful than the other methods.

No comments:

Post a Comment