Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

shivani_singhal
New Contributor II

num(Dual(F1, Match(F1, 'Jan', 'Feb', 'Mar'))) as F3 ??

A:

LOAD * INLINE [

    F1, F2

    Jan, 10000

    Feb, 20000

    Mar, 30000

];

NoConcatenate

B:

Load F2,

  F1,

  num(Dual(F1, Match(F1, 'Jan', 'Feb', 'Mar'))) as F3  // what does this expression mean..

  Resident A;

  DROP Table A;

4 Replies
jrepucci15
Contributor

Re: num(Dual(F1, Match(F1, 'Jan', 'Feb', 'Mar'))) as F3 ??

It returns the number portion of the selected "F1".

vinieme12
Esteemed Contributor II

Re: num(Dual(F1, Match(F1, 'Jan', 'Feb', 'Mar'))) as F3 ??

using NUM( over DUAL( is unnecessary and meaningless

We use DUAL() to assign numeric value to a text

but by using NUM( over Dual( we are only retaining the number returned by Match(), it should just be

Match(F1, 'Jan', 'Feb', 'Mar'))) as F3

Match() returns the position of the value found,

example if F1 was Jan it would return 1, if Mar  then 3...

Re: num(Dual(F1, Match(F1, 'Jan', 'Feb', 'Mar'))) as F3 ??

You might as well try with

Month(Date#(F1,'MMM'))

hope this helps

regards

Marco

Highlighted
shivani_singhal
New Contributor II

Re: num(Dual(F1, Match(F1, 'Jan', 'Feb', 'Mar'))) as F3  ??

Hi John, Vineeth, and Marco,

I got all the points from all of  you three. But I want to confirm that...Is it giving any concept of UNSELECTED VALUE FETCHING..??

Regards,

Shivani Singhal