Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Not applicable

Problem with expression labels

Hello everyone,

I have a data like this it's a world wide customer data of a company

I'm making a straight table based on customer countries and locations

I want separate label of country name for each colomm

When I'm trying to label my customer countries by using a set variable in script it's not showing any error and at the same time it's not giving me any output

My expression on script side is this

For a=1 to 40

Set vcountry $(a) = fieldvalue( 'Country' , $(a));

When I'm trying to display labels with above variables it's not showing any data

Like vcountry1 =

Vcountry2 =

So can u suggest me any way that I can label my each and every colomn using loops in scripting

Or is there any wrong in my script .

Thanking u all


4 Replies
Not applicable

Re: Problem with expression labels


try this syntax. I believe you should use let instead of set:


For a=1 to 4

     let vcountry$(a) = fieldvalue( 'Country' , $(a));


Good luck,



QlikView Consultant

Not applicable

Re: Problem with expression labels

Hi Jonas

Thanks for your reply

I tried let instead of set but when I'm using let now it's not even showing me the variables vcountry also

Is there any other way to solve this ...

Thanks a lot Jonas


Valued Contributor III

Re: Problem with expression labels

Hi Brad,

If you want the name as Column then just drag the dimension to top of the expression. It will serve your purpose.

In the attach application I have displayed both ways,

I hope this helps.


Not applicable

Re: Problem with expression labels

Thanks Deepak ,

I know we can do that in a pivot table but my req. is a straight table and i'm trying to write a loop for a runtime variable which stores those values in the specified colomn ...

thanks a lot