ANSWERED - Flat file problem - input column is 1252 and is required to be 65001

  • I am only trying to copy a whole table into a flat file, with column names and all. I made a blank txt file and assigned it a connection manager. Then I connected the source

    table to a FF destination.

    The flat file destination has the error -

    Error 8 Validation error. Data Flow Task Flat File Destination [16]: The code page on input column "My_Code" (56) is 1252 and is required to be 65001. Package.dtsx

    I don't know why this happens and how to fix it. Please help me to fix this.

    ----

    Guess what ! I figured it out accidentally while thinking about it. Solution -

    Go to the connection manager of FF. Your code page will be 65001 ie UTF-8. Set it to 1252 ie ANSI - Latin I.

    Then, if you see a warning, reconnect the two components.

    What happened, why it happened,I have no clue.

  • That's really helpful. New to SSIS and hit this error and I've been scratching my head for the past half hour.

    Nice one!

  • FYI

    I had a simple extract package ... working fine.

    I went in and added a column to the extract proc, added the column to the destination file.

    Opened this SSIS package refreshed the meta data and mapped the new column in the data flow task from proc to file.

    Then when running in debug I got this exact code page error on an EXISTING column that had not changed position nor data type.

    The solution was to change the code page of the destination file connection to the invalid suggestion in the error msg (65001) run it so it fails again then switch the code page back to the original correct setting 1252 and run again.

    happy happy.

  • In my case, I am getting the data from a SP and dumping it into a text file. I need the text file to be Code Page 65001 (UTF-8) per client request.

    The problem was one of the fields in my SP was of type char, I did a cast to nvarchar(1) and then I was able to set the Code Page to 65001.

    Thanks

  • My issue was that I had a flat file input, doing a lookup against a database, and my matched and unmatched output files were giving this complaint. I had changed my input file because the provider of it had added extra columns since the last time I used it. Somehow, and I can't fathom how, the code page got changed to 65001. As soon as I flipped it back to 1252 everything was fine. Thank you so much for posting this, I was getting tired of beating my head against the wall.

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply