Data Conversion In SSIS

  • Greetings All,

    I am loading the data from a csv file where coulmnd datatype is in varchar.

    I want to convert it in numeric/real.

    How can I achieve this?

    Plz suggest.

    Many Thanks!!

  • Use a data conversion task on the data flow pane of your DFT to convert the data types.

  • I have used the data conversion transformation.

    It's giving me this following error:

    "[Data Conversion [46]] Error: Data conversion failed while converting column "amount" (44) to column "Copy of amount" (140). The conversion returned status value 2 and status text "The value could not be converted because of a potential loss of data.". "

  • Ah that old chestnut, struggled with that a number of times in the past myself, what I usually do is dump it into a primary holding table as all varchars, then use a sql script to convert from holdling table to a stagaing table.

    You can try modifing the csv file on the flat file connection manager to say this column is a numeric but I struggled with that as well.

  • Thanks for the response.

    I was so dumb I was not thinking in the other way .

    It is so simple. Thnx a lot. 🙂

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

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