i have 10 skus and i am trying to find the customers that have not ordered some of the skus. so...if a customer has only ordered 2 of the 10, i want the sales of the 2 but 0 next to the SKUs they have not ordered. i cannot get this to work. any thoughts?
You want to display both transactions that exist and those that could have existed. It is quite well possible if you go for a cross join/union:
If you have 10 SKU's and 100 customers then a cross join between SKU and Customer dimensions will yield 10*100 = 1000 records. Define a sales of 0 (zero) for these records and union this query with the query that fetches the sales for the existing SKU/customer combinations.
Apply the correct aggregation to the sales item and the result should be 1000 rows with:
1. Actual sales
2. Sales = 0 for those combo without any sales
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.