Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
Hello,
I am trying to solve a problem in power bi that i was able to solve in Excel fairly simply. I have 3 columns in my data --
1) last 12 months sales
2) Total Market Sales
3) Item Category
I created the following measure to evaluate my revenue share in the overal market:
Here is a sample of the data. So I want to be able to see what our Total market share is (12% in image). I would like to keep this as a static measure. Then I would like create a new measure that uses the static measure and if my company's market share for a particular category is less than my companies total market share (12%), I would subtract 12% from the market share in that category.
Assume you have the following table named "MS".
Write the following measures:
PYR = SUMX(MS,MS[TTS PY Revenue])
MR = SUMX(MS,MS[TTL Market Revenue])
Market Share = DIVIDE([PYR],[MR],0)
Opportunity =
VAR CategoryShare = [Market Share]
VAR TotalMarketShare = CALCULATE([Market Share],ALL(MS[Category]))
VAR Result = MAX(TotalMarketShare-CategoryShare,0)
RETURN if(Result>0,Result,BLANK())
This will give the following result.
This is fairly simple. But need to know your actual table structure and field names. Please post the table structure, field names, and some sample data here.
User | Count |
---|---|
107 | |
88 | |
81 | |
76 | |
71 |
User | Count |
---|---|
112 | |
104 | |
96 | |
74 | |
66 |