Forum Discussion
chat_peters
Helper III
4 years agoAggregation with USERELATIONSHIP
I have data model with 4 tables (I don't have much freedom to make changes to it) Order Fact, Buyer Dim, Caller Dim and People Dim. Sometimes the buyer and the caller can be the same person and som...
- 4 years ago
Hi chat_peters ,
Is what you want something like this?
Measure = COUNT ( 'Order Fact'[Order ID] ) + CALCULATE ( COUNT ( 'Order Fact'[Order ID] ), USERELATIONSHIP ( 'PeopleDim'[Id], BuyerDim[BuyerID] ), 'Order Fact'[Caller different Buyer] = 1 )Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
chat_peters
Helper III
4 years agoI made this measure but it's not working, it's only taking into consideration when the buyer is the same as caller.
Total Orders with filter_2 = CALCULATE(
COUNT('Order Fact'[Order ID]),
USERELATIONSHIP(BuyerDim[BuyerID],PeopleDim[Id]),
FILTER(
'Order Fact',
OR(
'Order Fact'[Caller different Buyer]=1,
'Order Fact'[Caller same Buyer]=1
)))