Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I created straight table in the Qlik Sense without any Expression. The table contains raw data therefore, all the fields are dimensions.
I created one flag_LastMonth for the last month data in the calendar.
Now, I would like to last month data in the straight table with this flag. Without this flag, the table shows all the data from 2020.
How to fix this thing?
Thanks
I think that is working
=If (flag = 1, field)
un-Checked -> include null values (date field dimension)
We had the same challenge in SaaS with a straight table showing all historic data instead of just last month. What worked for us:
• Create a flag in the data model like Flag_LastMonth = If(DateField >= MonthStart(AddMonths(Max(TOTAL DateField),-1)) and DateField <= MonthEnd(AddMonths(Max(TOTAL DateField),-1)),1,0).
• Then in the table use that flag as a dimension filter or in the measure set-analysis to only include rows where Flag_LastMonth=1.
• Also uncheck “Show zero values” under Data Handling so rows that don’t meet the flag are hidden.
It’s not totally seamless (you’ll need the flag logic maintained in the model), but it gives the correct “just last month” view until there’s a built-in toggle for it.