Reputation: 429
In the lookup transformation, when matching on two columns is there a way to specify "or" condition instead of an "and"?
I can achieve the same thing by using a condition component after a lookup transformation, but that will create a lot of duplicate branches
Upvotes: 0
Views: 1347
Reputation: 5256
Practically, OR match means that if the first comparison yielded no match, try the second. Below are my thoughts how to program it in SSIS.
In Lookup transformation, specify as an action for no match rows Redirect rows to No Match Output, then specify lookup query only for the first match column. This Lookup will have two regular outputs, Lookup Match and Lookup No Match. On the No Match output, add another Lookup checking for the second column. Then combine results with Union All transform.
Upvotes: 1