SSIS Ragged Right - conditional split -
06-11-2008
, 08:49 AM
I am trying to take a ragged right text file and import into a single table.
The table is flatten out so each row type will populate different columns.
It is broken out by the first column.
sample source data: extended columns not shown
10|20080603235132|_BINDDGB7RCNIGc|xxx (AT) yahoo (DOT) com|44.4.444.44|h
1|20080604170011|_BIRwJbB7RQ95BX|xxx (AT) austin (DOT) com|S|1|xyz (AT) austin (DOT) com
20|20080604183534|_ hp?c[]=QkMwNzQtRU0=
3|20080604170011|_
I am using a data flow which contains a flat file source/connection
manager/ragged right as my source, then a conditional split task using the
below to split the rows out. For each condition I have a script
transformation and use an array (script) to separate the data out.
This all works well. For each script task I have a ole db destination. I
run the package but it never completes. Some of the tasks complete by
turning green but others are in yellow and it is like it is conflicting with
something. I create a flat file with just 20’s or 1’1 or 10’s and it
completes without problems. The source rows are in no guaranteed order.
SUBSTRING(EventLine,1,(FINDSTRING(EventLine,"|",1) - 1)) == "20"
SUBSTRING(EventLine,1,(FINDSTRING(EventLine,"|",1) - 1)) == "1"
SUBSTRING(EventLine,1,(FINDSTRING(EventLine,"|",1) - 1)) == "10"
SUBSTRING(EventLine,1,(FINDSTRING(EventLine,"|",1) - 1)) == "30"
SUBSTRING(EventLine,1,(FINDSTRING(EventLine,"|",1) - 1)) == "3"
SUBSTRING(EventLine,1,(FINDSTRING(EventLine,"|",1) - 1)) == "2"
Thanks
Landon |