Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Table 1:
Id,product,area,amount,trend,cur_1,current_2
1,tv,hyd,1000,100,Abc,d
2,laptop,bang,2000,200,axc,fgh
3,mobile,mum,3000,300,Sgt,h
4,cars ,Pune,4000,400,abc,d
5,bike,Delhi,5000,500,abc,d
Table2:
Min,max,Abc,newabc,trend
0,10,0.01,0.02,100
11,20,0.03,0.04,200
My requirement is if abcd trend multiply with abc thath
means(100*0.01) otherwise trend multiply newabc (100*0.02)
Not sure I understand your requirement very well, can you please re-explain?
Hi sunny
both table common field trend and curr_1,current_2 fields Data combined, once combined curr name like
abcd
axefgh like this ok.
so if name abcd trend multiply second table abc field
If not abcd than trend multiply with newabc field
If abcd =(100*0.01) multiply
not abcd =(100*0.02).
Like this?
Since only tv and laptop product have Abc and newabc values available we see a result for them. rest all becomes 0. Is this what you intended to get????
Script:
Table1:
LOAD *,
cur_1¤t_2 as Check
Inline [
Id, product, area, amount, trend, cur_1, current_2
1, tv, hyd, 1000, 100, Abc, d
2, laptop, bang, 2000, 200, axc, fgh
3, mobile, mum, 3000, 300, Sgt, h
4, cars, Pune, 4000, 400, abc, d
5, bike, Delhi, 5000, 500, abc, d
];
Table2:
LOAD * Inline [
Min, max, Abc, newabc, trend
0, 10, 0.01, 0.02, 100
11, 20, 0.03, 0.04, 200
];
Hi,
another solution could be:
=If(cur_1¤t_2 like 'abcd',Abc,newabc)*trend
hope this helps
regards
Marco