Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Date Dimension

Trying to create a Date Dimension using 'completed_date' field.  Basically I want to use this Dimension for x-axis of chart, where I want it to include days that fall within the last 60 days.  Currently I have tried these expressions:

Date(Floor([completed_date]-60)), but all the days loaded when I used this one

Date(Floor(Max([completed_date]-60))), but apparently "invalid."

Any help will be appreciated

1 Solution

Accepted Solutions
pradosh_thakur
Master II
Master II

something similar to

if completed_date is a date

if(floor(completed_date)>= num(today())-60 and floor(completed_date) < = num(today() ),completed_date,null())

suppress null.

you may not need the num or floor function as well. Make sure you have dates as date and not as string.

Learning never stops.

View solution in original post

2 Replies
pradosh_thakur
Master II
Master II

something similar to

if completed_date is a date

if(floor(completed_date)>= num(today())-60 and floor(completed_date) < = num(today() ),completed_date,null())

suppress null.

you may not need the num or floor function as well. Make sure you have dates as date and not as string.

Learning never stops.
Anonymous
Not applicable
Author

Thank you!  So far I think it is working.