Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have two lists, A and B. I would like to write a script: If items from list A is in list B, then replace with blank. Similar to the Exclusion definition in Set Analysis.
Hi!
I didn't get the whole task, but could you see on script bellow?
A:
Load
itemA
from ...;
B:
load
itemB
from...
where not exists(itemA, itemB);
load
null() as itemB
from ...
where exisis(itemA, itemB);
Exists() function wrapped in a Not() in a WHERE clause of the LOAD statement should work for you. If there is more than one key-field you might have to construct a temporary key. You might even have use of the Mapping Load with an AppyMap.
Could you give us more specifics? Like how is the structure of these "lists"? Is it tables and what are the fields/columns that should be used to match them?
Tried but doesn't seem to work. On Reload, it says that it cannot find itemA in the Where clause. How would the load for itemB knows of the existance of itemA to evaluate the Where clause?
I did this and it worked:
A:
Load
itemA
from ...;
Load * where not exists(itemA,itemB);
load
itemB
from...;