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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
dleelearn
Contributor II
Contributor II

How to group the count by distinct (Set Analysis)

dleelearn_0-1658230945712.png

Attached show the distinct date of GRN  with expression: =Count({<[Trading Year]=,[Trading Month]=,[Trading Week]=,[Date]=>}distinct([Weekly GRN Date]))

Its current result shows Count of Date = 3

I would like to group it according to trading week as well so the count result =1.
 I am thinking to use aggr but show me the same result =3 .

=aggr(Count(distinct{<[Trading Year]=,[Trading Month]=,[Trading Week]=,[Date]=>}([Weekly GRN Date])),[Trading Week])

How should i do it? Pls help . 🙂

 

Labels (1)
1 Reply
Or
MVP
MVP

I'm not sure I understand your request, but if you're looking for a distinct count of trading weeks, rather than dates, why not count that field rather than the date field?