Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi
I'm trying to create a graph to show by week (x axis) and status (stacked) the number of customers that have placed their first order in that week.
I can't write this into the script as the count needs to change based on which promotion is selected in a filter.
I think i need to use an aggr but i'm not sure if i write this as a calculated dimention or within the chart expression.
can any one help please?
essentially: count the customers in each week where their first order fits xyz criteria.
many thanks
H
I think i have solved my issue using a calculated dimention
Aggr(min({<ItemJobNumber = p([Job Number])>} [Financial Week]), CustomerNumber)
This will be much easier to answer if you can upload your qvw or a representative sample. That way we don't need to guess at fields names or the data structure, and you will get more accurate and useful responses.
Preparing examples for Upload - Reduction and Data Scrambling
May be just flag the first encounter with the customer in the script. This should still allow you to be dynamic. May be if you can share some sample data, it can be demonstrated.
Hi
Thanks for your comments so far, apologies but I can’t provide a sample set of data at present.
So far I have Financial week and Status in the dimensions, and the following in the expression;
count ({<ItemJobNumber = p([Job Number])>}distinct CustomerNumber)
I just need to restrict the count of the CustomerNumber to the first instance the criteria above is met.
I think i have solved my issue using a calculated dimention
Aggr(min({<ItemJobNumber = p([Job Number])>} [Financial Week]), CustomerNumber)