Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Set analysis and variables

I have a problem, I have a table with a legal size of year and quarter, I need to count the values ​​for the corresponding period

1.png   2.png

I have two variables

var1.png var 2.png

The problem is when I put the variable x in the set analysis, this does not give me any results, next place the formula with a value written to validate that if the data exists, please help me, thanks



tabla.png

10 Replies
Vasiliy_Beshentsev
Creator III
Creator III

Hi, maybe that helps:

4.5.3 Using a variable storing integer members

With integer keys, you need to enclose the variable name between double quotes:

{<TIME_KEY = {"<$(vFirstPeriod)"}>}

Or {<TIME_KEY = {"<$(=vFirstPeriod)"}>}

The periods between two dates:

{<TIME_KEY = {">$(vFirstPeriod) <$(=vLastPeriod)"} >}

sunny_talwar

May be try by adding an equal sign within your dollar sign expansion and use Single or Double quotes

Count({<Periodo = {"$(=vPeriodoSet)"}>} @Id_Recurso)

Anonymous
Not applicable
Author

Try double quotes but still not working, thanks

Anonymous
Not applicable
Author

Try double quotes and the equal sign but still not working, thanks

sunny_talwar

My bad, try with vMaxPeriodo

Count({<Periodo = {"$(=vMaxPeriodo)"}>} @Id_Recurso)

Anonymous
Not applicable
Author

Thanks Sunny but still not working,


vMax.png


If I put the variable with double quotes and the equal sign, this does not throw me nigun value


vmaxperiodo.png

sunny_talwar

Would you be able to share your qvf to take a look at this?

Anonymous
Not applicable
Author

Sure, what I want is to count the resources dynamically according to the dimension, if it is only the year of the last month of the year, if it is only quarter of the last month of the quarter and if it is monthly for each month, thank you very much

Vasiliy_Beshentsev
Creator III
Creator III

Like that?

2017-05-31 17_23_41-Clipboard.png