Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi Community,
I need one clarification..
LOAD *, Dual(Category, Cost) as Dual;
LOAD * Inline [
Date, Category, SubCAT, Cost
1/1/2012, LapTop, SML, 50
5/5/2012, LapTop, SML, 300
1/1/2012, A/C, SML, 310
3/2/2012, A/C, Big, 240
3/2/2012, Nokia, MDM, 160
7/7/2012, Laptop, MDM, 90
9/18/2012, Samsung, SML, 25
9/30/2012, Samsung, Big, 21
];
If i am using DUAL() function, Dual(Category, Cost) as Dual
what will happen here??
Please can you explain anyone???
is this only sorting purpose????
Paul,
your field Dual will contain both the textual value = Category and the numeric value = Cost. So, when the field is used as a chart dimensions or everywhere else, where the text is expected, the textual value will be displayed, and when the field is used for sorting or math, the numeric part will (or can) be used.
Think of the field Month - it shows you Jan, Feb, Mar, ... yet it's sorted numerically. Your dual field will act similarly.
cheers,
Oleg Troyansky
QlikView Your Business: An expert guide to Business Discovery with QlikView and Qlik Sense
Not really sure why you are creating Dual field, because I am almost certain that you can use Cost field to sort the same way as it would be sorted by Dual field. So not really sure what benefit it is giving here.
Hi Paul,
This link may help you, given clear explanation.
QlikView Addict: QlikView Functions: dual()
Best Regards,
Ganesh Reddy
HI,
Dual provides multi datatype feature, generally this is used for Sorting functions. Check this link for detailed explanation
Regards,
Jagan.