|
|
Archives of the TeradataForum
Message Posted: Thu, 18 Oct 2007 @ 12:20:19 GMT
Subj: | | Re: Conditionally Converting a Many to One relationship |
|
From: | | Victor Sokovin |
| Has anyone coded this kind of thing before? I tried coding this with nested IF and case statements but it doesn't seem to work. The only
way I can get it to work is by creating multiple staging tables but I was hoping this could be programmed in a loop of some kind. | |
I think you can accomplish this easily if you use such set operators as MINUS or INTERSECT. You can store all your standard sets (and their
codes) in one reference table and compare them to the attribute value sets for each item in your main table. If you use MINUS and find that the
difference of the sets is NULL for a certain standard set then <Bingo!> you've got the code you were looking for.
Regards,
Victor
| |