Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

current week's date

Hi Experts,

i have a date field called 'ORDEREDDATE'.

In my pivot table, i want to display current week's dates alone.

i tried the dimension as date(week(max(ORDEREDDATE))). but i m getting error.

can someone help me to correct the expression please..

Labels (1)
1 Solution

Accepted Solutions
sunny_talwar
MVP
MVP

May be this:

If(ORDEREDDATE >= Max(TOTAL ORDEREDDATE) - 7, ORDEREDDATE)

View solution in original post

5 Replies
sunny_talwar
MVP
MVP

How about this:

If(ORDEREDDATE >= WeekStart(Today()), ORDEREDDATE)

and select 'Suppress When Value Is Null'

sunny_talwar
MVP
MVP

Alternatively you can use Set Analysis as well

{<ORDEREDDATE  = {"$(='<=' & Date(WeekStart(Today()), 'DateFieldFormatHere'))"}>}

Assuming you don't have dates in the future.

Not applicable
Author

Hi Sunny,

Instead of Weekstart(Today()), how can i do this for Max(ORDEREDDATE)

sunny_talwar
MVP
MVP

May be this:

If(ORDEREDDATE >= Max(TOTAL ORDEREDDATE) - 7, ORDEREDDATE)

trdandamudi
Master II
Master II

May be this: (I modified Sunny's expressions):

If(ORDEREDDATE >= Max(ORDEREDDATE))


Or in Set analysis:


{<ORDEREDDATE  = {"$(=Max(ORDEREDDATE))"}>}