Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Read about Qlik’s Response to COVID-19 Read the Letter, Join the Group.
Not applicable

field as name of label

Hi everyone!

It's me again,

Now I have 2 new ideas that are not working for me

1) I need to put a field of a table as Label of several expressions.

2) I need to obtain data a table with data of last 13 weeks and it replicate the last week.

First, I need to build a table with TOP 10 customer and information of their debts regarding last 13 weeks (TOP10 according last week= with that I'm OK). The idea is like:

and for the most old week I have following definition:

As you can see, I need that in label appears the field "PERIOD" (201707, 201706, 201705, ....) which corresponds to the weeks. The 13 rows of data are since oldest week 1 = 201647 until the most newest week 13= 201707. And for every row I need that appears the debt of the week = period.

I'm using the formula sum({$<Period={$(=Max(Period))}-12>}[> 180 days]) for week 1, sum({$<Period={$(=Max(Period))}-11>}[> 180 days]) for week 2 until sum({$<Period={$(=Max(Period))}}[> 180 days]) for week 13, but is not working because reply the last week information (201707) every of 13 weeks.

I hope somebody can help me

Thanks

Tags (2)
1 Solution

Accepted Solutions
Highlighted
Partner
Partner

Re: field as name of label

Your set analysis function is not correct, there is a curly bracket in the wrong place.

This is your set analysis function:

sum({$<Period={$(=Max(Period))}-12>}[> 180 days])


It should be

sum({$<Period={$(=Max(Period))-12}>}[> 180 days])


View solution in original post

5 Replies
Highlighted
Esteemed Contributor III

Re: field as name of label

You cant use $Field(Period) as $Field is not a function here? Can you share this sample app to work on? And what is your expected output to look like?

Highlighted
Honored Contributor

Re: field as name of label

Ok for your field labels you just need to match what you have in your set analysis so for example:

Max(Period)-11

For the other parts I can't understand your requirements I am afraid

Highlighted
Partner
Partner

Re: field as name of label

Your set analysis function is not correct, there is a curly bracket in the wrong place.

This is your set analysis function:

sum({$<Period={$(=Max(Period))}-12>}[> 180 days])


It should be

sum({$<Period={$(=Max(Period))-12}>}[> 180 days])


View solution in original post

Highlighted
Not applicable

Re: field as name of label

Thanks!

Highlighted
Not applicable

Re: field as name of label

Thanks!