Join us for an expert-led overview of the tools and concepts you'll need to pass exam PL-300. The first session starts on June 11th. See you there!
Get registeredPower BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.
Hello!,
I have an expression (let's say SUM(Sales[Qty])) that I want to put into a matrix, but I want to evaluate different periods of time in columns.
For Example, calculating the sum of sales cummulated, last quarter, last month and last 6 weeks.
Sales | YTD | Last Quarter | Last Month | Week 5 | Week 6 | Week 7 | Week 8 | Week 9 | Week 10 |
Qty | 21000 | 7500 | 3000 | 800 | 700 | 400 | 600 | 1000 | 900 |
I can generate a measure for each of them with CALCULATE ( SUM(Sales[Qty]), FILTER(Calendar, Date = XXXX)) but I would like to avoid creating too many measures.
Is it possible, to generate a measure with multiple results? and expose those into columns in a matrix?. For example, defining each measure into variables (VAR) but allowing multiple RETURN. Any other approach to avoid multiple measure creation is also a possibility.
Thanks
Solved! Go to Solution.
Hi,
I think maybe calculation groups may work for you:
REDUCE the # of measures with Calculation Groups In Power BI - YouTube
Hi,
I think maybe calculation groups may work for you:
REDUCE the # of measures with Calculation Groups In Power BI - YouTube
thank you, that is exactly what I was looking for.
The only thing that I think is not possible is to dynimically change the name of the measure depending on the content (for example for the las 6 weeks, each column to show the number of each in the column name).
User | Count |
---|---|
85 | |
79 | |
64 | |
52 | |
46 |
User | Count |
---|---|
101 | |
52 | |
41 | |
39 | |
37 |