Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello All,
I am trying to get the average value for my currency conversion,
Here is the logic I am trying to apply in QlikView,
Set vCurrencyEUR = select avg(currency_ rate) where Reimburse_Cur=EUR and Spend_Cur =USD
Set vCurrencyINR = select avg(currency_ rate)where Reimburse_Cur=INR and Spend_Cur=USD
Please help me how to convert this into working QlikView scripts.
Try with as expression :
=avg( {<Reimburse_Cur={"EUR"}, Spend_Cur ={"USD"} >} currency_ rate)
=avg( {<Reimburse_Cur={"INR"}, Spend_Cur ={"USD"} >} currency_ rate)
But Set expression not worked in the load script. You must be in front end.
You would need to build a summary table. Example for first one.
EURCurrency:
Load
avg(currency_rate) as AvgCurrencyRate
Resident YourDataTable
where Reimburse_Cur='EUR' and Spend_Cur='USD';
let vCurrencyEUR= peek('AvgCurrencyRate');
Drop table EURCurrency;
Thank you Jean and Wallo for your suggestions. Let me work on both suggestions and will get back to you