Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Add a calculated field from the script

Hi ,

In the image attached I have a table loaded in line called 'Tasas' where the field 'Tasa' is a currency USD rate per month.

The table called 'APUNTES' has a field called 'SALDO' have amounts in local currency. This table is not loaded in line.

I 'm just looking for the way to add to the table 'APUNTES' a field called 'USD' which would be USD = SALDO/Tasa.

When I wrote SALDO/Tasa AS USD, the script did not recognize 'Tasa' howevere it was previously loaded.

An idea please.

Thanks

usd.png

1 Solution

Accepted Solutions
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

You can use a mapping table and applymap:

TasasMap:

mapping load * resident Tasas;

APUNTES:

Load *, applymap('TasasMap',DIV_MES_AÑO) * SALDO as USD

from ...etc;


talk is cheap, supply exceeds demand

View solution in original post

1 Reply
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

You can use a mapping table and applymap:

TasasMap:

mapping load * resident Tasas;

APUNTES:

Load *, applymap('TasasMap',DIV_MES_AÑO) * SALDO as USD

from ...etc;


talk is cheap, supply exceeds demand