I'm having an issue with SQL Server 2008R2 64-bit with a BIDS Data Flow Task specifically.
I'm trying to export data from a SQL Server database to a flat file. I have narrowed the problem down to one specific field, which is type NVARCHAR(100) .
I altered my query to only include records that are a problem:
SELECT PoNum FROM SALES WHERE CAST(PoNum AS VARCHAR) != PoNum;
This allowed me to lower the record count to 160 records.
Then I used the 'TOP' command to get as many records to work as I could, which narrowed it further to the following 3 records which cause the problems (I pasted them and included a screen shot).
Ð¿Ñ¿ÑÑ¿Ð¾Ð²Ð¾Ð¹ - Innovate
My flat file settings look like this:
And the column in question is set as such in the flat file connection manager:
: Unicode String [DT_WSTR]
When I hit run, I get this message:
[Flat File Destination ] Error: Data conversion failed. The data conversion for column "NumAtCard" returned status value 4 and status text "Text was truncated or one or more characters had no match in the target code page.".
I have tried the following:
1. Setting the column width to 250 in the advanced tab in the flat file manager
2. Setting TextQualified to False
3. Changing the column type to DT_String , DT_Text, and DT_NText
If I ignore these 3 records, everything works perfectly for all records in the table (100,000+). It's obviously an encoding problem, but I can't figure out how to fix it.