Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, all!
I've read a lot about preceding loads and have done my very own super-low-tech diagram.
Did I get it right? Please ignore the SQL * for the database query. I was just too lazy to write the fields again.
Looks right to me.
Best,
S
yay! Thanks!
You did get it right, but you can also do a preceding load on a preceding load for a better performance increase especially when using mapping tables. You won't see much of a performance gain if you aren't performing an expression in your load. Take the following example:
UnitCost_Map:
MAPPING LOAD
ProductID,
UnitCost;
SQL SELECT * FROM Products;
LOAD LineSalesAmount - CostOfGoodsSold AS Margin,
*
;
Order Details:
LOAD
LineSalesAmount - CostOfGoodsSold AS Margin,
*
;
LOAD
Discount,
LineNo,
OrderID,
ProductID,
Quantity,
UnitPrice,
UnitPrice * Quantity * (1 - Discount) AS LineSalesAmount,
applymap('UnitCost_Map', ProductID, 0) * Quantity AS CostOfGoodsSold;
SQL SELECT * FROM 'Order Details';
Camilla,
"Thanks" is nice, but you can also mark sunindia's answer as correct, and thus give him some points
You can mark your own answer as correct, but no points will be added.
Ah - that's interesting - from my inbox I don't have that option. Thanks for reminding me!!
Thanks, Nick - I almost put a note in my original post that I was assuming that there would be additional preceding loads, and that there would be aliases, expressions, etc....I just kept it very simple!