DTS stores the last {LF} in the table!!

  • Hi i have a csv file where the last column usually happens to be null. So my file is like this:

    1,2,3,,{LF}

    4,5,6,,{LF}

    7,8,9,,{LF}

    {CR}

    I run the dts export from csv file to db and it doesnt save the last row (column5) in the table us null. instead it stores the {LF} character. Ascii =10. How can i resove this problem.

    the csv comes from a third party application. the DTS needs to un automatically and somehow resolve that last problem on its own. but how??? is there a code that can trim the last character in the last line to delete the last {LF} or some query in DTS that can achive this.....

  • You can use ActiveX transformation property and look for the ascii value in the first column and exclude it if it has CR. That will exclude the last line to be loaded.

    Else you can load it in to the table and as step 2 you can delete the row that has {CR} as the first column.

    Hope this helps

    Thanks

    Sreejith

  • Have you tried to change the RowDelimiter?

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

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