AlikView Pick Function

Simplicity is the ultimate sophistication. — Leonardo da Vinci

QlikView Pick function ought to be in your toolbox if you believe in the wisdom of Leanardo da Vinci.

Indeed, Pick function in QlikView simplifies your life as a developers and others who have to live with your legacy code after you decide to embark on other dreams of your life.

Back to Basics

let’s explore the Pick function if you never heard of it before. In a layman’s term, QlikView Pick function is akin to a nested if function.

For example,

Pick(N, ‘Bolton’,’Underwood’,’Smith’)

…will return Bolton if N=1 or it will return Smith if N=3. 

Imagine a life of a QlikView developer without a Pick function. Similar logic would require a nested if function..

If(N=1, ‘Bolton’, if(N=2, ‘Underwood’, ‘Smith))

Now that you know how powerful QlikView Pick function is, let’s explore some practical usage. I have found Pick function adding simplicity to my code when I blend it with other powerful QlikView functions such as Match or Ceil functions.

Pick function plays clever role along with Match function in this example. If Category = ‘Room Revenue’ then match function shows 1; it shows 2 for ‘Telephone’ .. so on and so forth. Pick function assigns a Description back to these numeric values that fall under ‘Revenue’ field.

Qlikview pick function example

By creating Revenue and Expenses fields, it becomes easy to show these values on a QlikView dashboard.

pick function example

As you can imagine, your life as a QlikView developer becomes simpler when you can write a simple Set Analysis syntax to display Revenue in the text box.

pick function in Qlikview

 

 

 

 

Simplicity is a virtue and Pick function is at your disposal if you want to master simplicity as a QlikView developer.

Elsewhere:

Getting the Max Value over Multiple Expressions via Qlikblog.at

Pick Function in QlikView via QlikShare

Keep QlikView Simple via QuickIntelligence


If you enjoyed this article, get email updates (it’s free).

Email Address: