Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all.
I need to find a count for all distinct WeekDays and then take the avg of that count for each of them
and then make a line chart with the weekdays (Sat, Sun,...etc).
avg(aggr(count({<[status] = {'0', '1'}>} distinct order_id),WeekDay))
I tried this but it's not working. In fact , it returns the same if i just do count({<[status] = {'0', '1'}>} distinct order_id)
Any suggestions?
Would you be able to share an image to show what you have and what you are looking to get? or some sample data?
Yes, I have this one which is the count of the order_ids for all Saturdays, Sundays etc of all years.
I need to calculate and show in this line chart a count for all distinct WeekDays and then take the avg of that count for each of them.
For example lets say on every Sat in history I counted 500 orderids.
but what is the expected count on any Saturday?
That's what I'm looking for.
Hey, the issue here is a WeekDay, qlik thinks that it is a function of a week day not a dimension. Create flag in Calendar called WeekdayTest(or something like that) and use it in the calc. I am sure it is going to work 😉
Hey!Thanks for your input! But Weekday is coming straight from a master calendar, shouldn't it work anyways? 😬
Is it blue or yellow when you use it in the set analysis?
It's yellow!
Did you try what I asked for?
I don't know how to create this flag, so I'm looking for it.
Any help accepted and welcome though!
In the master calendar add one line:
weekday(Date) as [WeekdayTest],