Michael843
Programmer
Hello!
I am experiencing a problem with the conversion of my DTS packages to SSIS packages (not really a conversion since I am just remaking them from scratch). I succeeded in converting the DTS packages into SSIS but when I went ahead and copied and adjusted it to a different txt and tbl I ran into a error. This specific txt had a timestamp inside it wich had to be converted into the table.
The problem:Some of the rows inside the timestamp column do not contain a timestamp but instead they are filled with spaces by the txt generator, if I try to convert this to timestamp to sent it to the table I get a conversion error on the rows filled with spaces!
In the DTS package this problem was solved using this ActiveX script:
If on the Flat File Source - Error Output I put the error output for the timestamp column on Ignore Failure it works perfectly fine! It sends the rows filled correctly to the table but the rows with spaces wich create a error he skips them and thus the value is replaced with NULL (wich I want!).
I need a method of using a expression/script/TRIM() function inside the Data Flow! I can't place a Script Task inside the Data Flow! This is only possible on the Control Flow but I need it to be in between my import and export in the Data Flow! - Please provide a solution to do this...
I am experiencing a problem with the conversion of my DTS packages to SSIS packages (not really a conversion since I am just remaking them from scratch). I succeeded in converting the DTS packages into SSIS but when I went ahead and copied and adjusted it to a different txt and tbl I ran into a error. This specific txt had a timestamp inside it wich had to be converted into the table.
The problem:Some of the rows inside the timestamp column do not contain a timestamp but instead they are filled with spaces by the txt generator, if I try to convert this to timestamp to sent it to the table I get a conversion error on the rows filled with spaces!
In the DTS package this problem was solved using this ActiveX script:
Code:
If (IsDate(Trim(DTSSource("statdate")))) Then DTSDestination("statdate") = DTSSource("statdate") End If Main = DTSTransformStat_OK
If on the Flat File Source - Error Output I put the error output for the timestamp column on Ignore Failure it works perfectly fine! It sends the rows filled correctly to the table but the rows with spaces wich create a error he skips them and thus the value is replaced with NULL (wich I want!).
I need a method of using a expression/script/TRIM() function inside the Data Flow! I can't place a Script Task inside the Data Flow! This is only possible on the Control Flow but I need it to be in between my import and export in the Data Flow! - Please provide a solution to do this...