Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey,
I have a table1 with a Customer field and another table2 with many fields, among them a field Customer. I 'd like to exclude from table2, the customers that are in Table1.
Any help on this??
Thanks
Hi, Try something like this.
T1:
LOAD CustID as LookupID,
Cust
FROM SourceTable1;
T2:
LOAD CustID,
Cust,
DOB,
Gender,
"Phone Number"
FROM SourceTable2
Where not Exists(LookupID,CustID);
DROP Table T1;
DROP Fields CustID, DOB, Gender, "Phone Number"; //Optional - comment this line if the other fields in T2 are relevant.
Thanks for the response!
If I 'd like to use a resident table, how could I do it?
T1:
LOAD CustID as LookupID,
Cust
FROM SourceTable1;
T2:
LOAD CustID,
Cust,
DOB,
Gender,
"Phone Number"
FROM SourceTable2;
NoConcatenate
Final:
LOAD *
Resident T2
Where not Exists(LookUpID, CustID);
DROP Tables T1, T2;