To Set the Identity Column in SSIS while Import into Text file

  • Hi,

    Greetings!!!

    While Importing/Exporting into text file destination new column should be add with identity set

    Thanks & Regards

    Indher Sarvade

    9930422371

  • I'm not sure what you mean about having an identity column in a text file.

    Do you mean a row number?

    If so, you can add that to the query pretty easily, using the Row_Number() function.

    - Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
    Property of The Thread

    "Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon

  • We definitely need more information. There really isn't an Identity property for a text file. You'd have to add a column using either ROW_NUMBER() in the query if you are using T-SQL for your source as Gus has mentioned, or you'd need to add a column in the data flow and increment it, probably using a variable and a script component (there may be a better way).

Viewing 3 posts - 1 through 2 (of 2 total)

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