Skip to main content
Announcements
See why Qlik is a Leader in the 2024 Gartner® Magic Quadrant™ for Analytics & BI Platforms. Download Now
cancel
Showing results for 
Search instead for 
Did you mean: 
danielnevitt
Creator
Creator

Limit Dimension by Date

Hi,

I am trying to limit a straight table by a dimension date.

The code I have written is =If(PRICING1_END_DT<=vToday,PRICING1_END_DT))

This isn't quite correct and it just removes the date if it is after vToday.  I would like the table to only show data where the PRICING1_END_DT is less than today, rather than blank the data in the field.

Any help is much appreciated.

Regards,

Daniel

1 Solution

Accepted Solutions
simondachstr
Luminary Alumni
Luminary Alumni

Are Suppress Zero-Values & Suppress When Value is Null checked?

View solution in original post

5 Replies
simondachstr
Luminary Alumni
Luminary Alumni

Can you tell us something about the format of PRICING1_END_DT and vToday.

danielnevitt
Creator
Creator
Author

Hi Martin,

Thank you for your reply.

vToday = Date(Today()) - format of this field is DD/MM/YYYY

PRICING 1_END_DT is a date field in the format of DD/MM/YYYY

Is that all the information you require?

Regards,

Daniel


Gysbert_Wassenaar

Try putting the limit in the expression. Suppose you want sum(Value) as expression. You can limit this to the required dates like this: sum({<PRICING1_END_DT={'<=$(vToday)'}>}Value)

You'll have to make sure that the variable vToday has the same date format as PRICING1_END_DT


talk is cheap, supply exceeds demand
simondachstr
Luminary Alumni
Luminary Alumni

Are Suppress Zero-Values & Suppress When Value is Null checked?

danielnevitt
Creator
Creator
Author

Hi,

Thanks that has solved the issue.  Sorry for not spotting this basic error.

Regards,

Daniel