Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I have many rows of transactions and they are categorised by two fields; BOOK and SECTOR. However I need to further categorise each transaction using an extra field called PRODUCT, which is not present in the database.
The product can be inferred by what the SECTOR or BOOK is. For example if the BOOK is 'EURO SSA' i want to assign the a PRODUCT of '€ Agency bonds' or if the SECTOR is CROSSOVER then assign a PRODUCT of 'CDS HY'.
I am not connecting directly to the database, rather our Qlikview developers have given me a raw qvw from which I am loading the data. Therefore my question is, how do I script these rules which specify which PRODUCT values are assigned to each transaction?
Then Rename your TRADES table (somewhere in the script you used before this section of script) as Trade_Temp, and then try like:
TRADE:
LOAD
*,
ApplyMap('MapProduct',DESK,ApplyMap('MapProduct',SECTOR, Null())) as PRODUCT
Resident Trade_Temp;
Drop Tables Trade_Temp, Data ;
I am doing a Binary load from another qvw and the TRADES table is in that.
Do i need to get the table renamed in the underlying qvw or can I do it in this one?
You can simply rename(in this app itself) like:
Rename table TRADES to Trade_Temp;
You guys are geniuses!!!!
That has worked perfectly. Thanks so much for your help