Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have a table called Orders and I also have a table called Customers
Here's what they look like:
orders:
Load Order_Number,
Customer_Number,
Order_Date,
Order_Item, etc.
sql select * from orders
customers:
Load Customer_Number,
Customer_Name,
Parent_Customer, etc
sql select * from customer
My dilemma is that I need to also get a name for the Parent_Customer and the only way to do that is to take the Parent_Customer field from customers
and I need to read the customer file again to get the name so I can add it to the file.
Would mapping work for accomplish this????
Can someone show me how this would work?????
Clear...
MapParCus:
Mapping
Load Customer_Number, Customer_Name;
sql select * from customer
Then add this statement to your load for table customer:
applymap('MapParCus',Parent_Customer) as ParCust_Name