Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All
I have below load script :-
Input:
LOAD * INLINE [
Unit_Price,Doc_Num,MODEL,item_cost,Customer/Vendor, Customer Name, Email, E-Mail
9,1,APPLE,4,CET00837-SGD, SUPER COMPONENTS (S) PTE LTD, sales@supercom.com.sg, sales@supercom.com.sg
9,1,NSI,8,CET00837-SGD, SUPER COMPONENTS (S) PTE LTD, sales@supercom.com.sg,
9,2,BANANA,3,CET01610-USD, GRAND VENTURE TECHNOLOGY LIMITED, contact@gvt.com.sg,
9,2,NSI,0,CET01610-USD, GRAND VENTURE TECHNOLOGY LIMITED, contact@gvt.com.sg, kimhong.chong@gvt.com.sg
];
Final Result i wish to get :-
Customer Name | MODEL | item_cost | Doc_Num | Unit_Price |
GRAND VENTURE TECHNOLOGY LIMITED | BANANA | 3 | 2 | 9 |
GRAND VENTURE TECHNOLOGY LIMITED | NSI | 9 | 2 | 9 |
SUPER COMPONENTS (S) PTE LTD | APPLE | 4 | 1 | 9 |
SUPER COMPONENTS (S) PTE LTD | NSI | 8 | 1 | 9 |
Above cell red color , org is 0 from Item_Cost, i need to replace it 9 from Unit_Price
Hope some one can advise me.
Paul
@paulyeo11 like :
Input:
LOAD Unit_Price,Doc_Num,MODEL,if(item_cost=0,Unit_Price,item_cost) as item_cost,[Customer/Vendor], [Customer Name], Email, [E-Mail]
INLINE [
Unit_Price,Doc_Num,MODEL,item_cost,Customer/Vendor, Customer Name, Email, E-Mail
9,1,APPLE,4,CET00837-SGD, SUPER COMPONENTS (S) PTE LTD, sales@supercom.com.sg, sales@supercom.com.sg
9,1,NSI,8,CET00837-SGD, SUPER COMPONENTS (S) PTE LTD, sales@supercom.com.sg,
9,2,BANANA,3,CET01610-USD, GRAND VENTURE TECHNOLOGY LIMITED, contact@gvt.com.sg,
9,2,NSI,0,CET01610-USD, GRAND VENTURE TECHNOLOGY LIMITED, contact@gvt.com.sg, kimhong.chong@gvt.com.sg
];
output:
@paulyeo11 like :
Input:
LOAD Unit_Price,Doc_Num,MODEL,if(item_cost=0,Unit_Price,item_cost) as item_cost,[Customer/Vendor], [Customer Name], Email, [E-Mail]
INLINE [
Unit_Price,Doc_Num,MODEL,item_cost,Customer/Vendor, Customer Name, Email, E-Mail
9,1,APPLE,4,CET00837-SGD, SUPER COMPONENTS (S) PTE LTD, sales@supercom.com.sg, sales@supercom.com.sg
9,1,NSI,8,CET00837-SGD, SUPER COMPONENTS (S) PTE LTD, sales@supercom.com.sg,
9,2,BANANA,3,CET01610-USD, GRAND VENTURE TECHNOLOGY LIMITED, contact@gvt.com.sg,
9,2,NSI,0,CET01610-USD, GRAND VENTURE TECHNOLOGY LIMITED, contact@gvt.com.sg, kimhong.chong@gvt.com.sg
];
output:
Thank you very much.