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: 
Abhi999
Contributor III
Contributor III

Lastest week count

Could some one help me on below query.

 

I want to count of orders weekly based on max in date field.

Labels (1)
1 Solution

Accepted Solutions
tresB
Champion III
Champion III

If you have a week field(if you don't, create it in the script using week()), you can try like:

Count({<Week={'$(=Max(Week))'}>}OrderID)

View solution in original post

3 Replies
tresB
Champion III
Champion III

You have given not much information. With that; you may try something like:

Dim : Week

Exp : FirstSortedValue(Aggr(Count(Distinct OrderID), Week, Date), -Date)

Abhi999
Contributor III
Contributor III
Author

Hi Tresesco, I am using KPI to show latest week , based max available date. 

Ex: I have data only upto last Monday, so I want calculate orders of last week. 

tresB
Champion III
Champion III

If you have a week field(if you don't, create it in the script using week()), you can try like:

Count({<Week={'$(=Max(Week))'}>}OrderID)