Combine application table and UD dimension information
Hi, I have an SQL data adapter that queries an application table, and one of the columns is the CostCenter. This CostCenter is also a dimension in our cube, where the table values correspond to the base-level members of that dimension. In the CostCenter dimension hierarchy, each cost center is either a descendant of Member A or Member B.
I want to add a column to the data adapter that indicates whether each cost center is a descendant of Member A or Member B, so that users can filter cost centers more easily in their dashboards. Does anyone have any ideas on how I could achieve this?
Nikpowar97 thank you for your reply. Option 1 is too complex in my case because the cost centers are not just children of Member A and B, are descendants at various levels down the hierarchy, so it would not be enough to join the Member and Relationship tables, I would need to do in a kind of recursive way.
I briefly tried the option 2 and I think it would work. However, I ended up implementing what I believe is an easier solution for my specific use case:
I have created 2 Literal value parameters each calling an XFBR rule returning the list of Member A descendant on one parameter and the list of Member A descendant on the other parameter, and then modified the SQL in the data adapter like this:
Select {Other Columns} ,CostCenter ,'A' As CostCenterType Where CostCenter (|!prmAList!|) UNION Select {Other Columns} ,CostCenter ,'B' As CostCenterType Where CostCenter (|!prmBList!|)