As part of a project I have run into a problem when I select a value of a dimension in a straight table.
I am sorry in advance about that the language is in hebrew 🙂
So in my straight table I have a "is Customer new" column which states whether the customer is new or "rejoining".
In this case Sara (the customer name in the 3rd column) is listed once as a new customer and in a different order as a rejoining customer.
My problem is that once I use a filter to show the rejoining customers only, Sara isn't shown because in a different occasion she's listed as a New customer. The same thing happens with every customer that is listen as both options of the column.
Here it shows only one column because there is no order when that customer is New
Does anyone have an idea how to solve this problem. Maybe some sort of set analysis?
I'm having a hard time understanding what your expected result / outcome is. In the first scenario, selecting only rejoining customer flag should result in only the first row being returned. Is that not what you are expecting? If so, could you explain the logic used to determine which rows to return?
Generally, if you want to have a customer status that will allow you to filter all customers who are currently "rejoining", you should set up a table with one row per customer which holds the correct status, rather than flagging each fact row individually. This can be achieved by loading the most recent status from the fact table for each customer (a simple enough group by Customer for the most recent record), but I'm not at all sure this is what you're trying to do here.
Assuming your dimension for the customer type (new/rejoining) is taken from the fact table or linked directly to the fact table, should should already be the case. However, without knowing what the data structure is, it's difficult for me to try and suggest a specific solution.