January 7, 2011 at 3:11 pm
Many empty rows in .csv file which I don't know how to clear out. So, in SSIS I pulled in the Conditional Split Task, and in editor are three columns:
Order, Output Name, Condition
Would this be an appropriate condition?: ISNULL([First Name]&&[Last Name])
What goes in Output Name? I just want to ignore empty rows.
Is there a good resource online for quickly getting up to speed with SSIS expressions?
Thanks.
January 7, 2011 at 3:18 pm
You'll probably want something along the lines of ( ISNULL( Firstname) == TRUE & ISNULL( LastName) == TRUE) ? 1 : 0 in a calculated field before entering the conditional split. I might be a hair off on the AND syntax, doing that from memory.
Then, in the conditional split, any row with CalculatedCheck = 1 goes to the output name 'Ignored rows'.
When you're done with the conditional split, you'll be able to pull multiple green data streams off the conditional split object. It'll ask you which stream from the split you want to use to connect to the next object. Use the defaultly named one, and ignore outright the conditionally split ignored one. They'll float away on the Aether and you'll never have to see them again. 😉
Never stop learning, even if it hurts. Ego bruises are practically mandatory as you learn unless you've never risked enough to make a mistake.
For better assistance in answering your questions[/url] | Forum Netiquette
For index/tuning help, follow these directions.[/url] |Tally Tables[/url]
Twitter: @AnyWayDBA
January 7, 2011 at 7:07 pm
OK, that helped me fix the syntax, but this did not redirect the 1000+ rows of white spaces I'm trying to redirect:
I set condition to:
ISNULL([First Name])==TRUE && ISNULL([Last Name])==TRUE
Output Name
'Ignored rows'
I didn't understand what you meant by multiple green data streams, Craig, and tried using DataReaderDest component as secondary output for Conditional Split, but nothing is redirecting.
January 7, 2011 at 8:19 pm
How can i build condition to evaluate an empty string (rather than NULL)?
January 7, 2011 at 8:46 pm
Oh Man, i just had the or operator in wrong place.
so, this worked to handle empty rows from source file:
Condition:
ISNULL([First Name]) == TRUE || [First Name] == "" && ISNULL ([Last Name]) == TRUE || [Last Name] == ""
Yay.
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply