Forum Discussion
lindafly618
8 years agoRegular Visitor
Handle data with different granularity within same table
Hi everyone, I'm rather new to Power BI and I'm tasked with following request. The data is something like this: CampaignID Flag Code Revenue Cost Camp1 Acq Business $10 $1 (Camp1...
- 8 years ago
Hello lindafly618
Here is the solution :
1 - Create those measures (right click - add measure)
Measure = MAXX(DISTINCT('Table'[CampaignID]);MAX('Table'[Cost])) SumCost = SUMX(DISTINCT('Table'[Flag]);[Measure]) SUMRevenue = SUM('Table'[Revenue]) ROI = [SUMRevenue]/[SumCost]2 - Add a slicer with Flag selection
3 - Add a Card Box or wathever you want for ROI
Here is the result :
Have a good day
- Quentin
quentin_vigne
8 years agoSolution Sage
Hello lindafly618
Here is the solution :
1 - Create those measures (right click - add measure)
Measure = MAXX(DISTINCT('Table'[CampaignID]);MAX('Table'[Cost]))
SumCost = SUMX(DISTINCT('Table'[Flag]);[Measure])
SUMRevenue = SUM('Table'[Revenue])
ROI = [SUMRevenue]/[SumCost]2 - Add a slicer with Flag selection
3 - Add a Card Box or wathever you want for ROI
Here is the result :
Have a good day
- Quentin
lindafly618
8 years agoRegular Visitor
Forgot to @ you in the previous message. Thanks.