The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi,
I have a What If parameter in my report on which the user can dynamically choose a value between 1 and 1000 ('ValueParameter').
Now I want to create a visuel which uses the values of 1 other column ('Column1') multiplied by the number chosen for the ValueParameter.
Should I create a new column to do this, or a measure? Both of them are not working.
Is it because I don't won't to aggregate my data? (I want to use the values in Column1 to create the same amount of new data, so no calculating with the sum/mean/...). How can I still do this?
Thank you!
Hey,
you need to tables, one that contains the values from you parameter (I assume that this table is called "Parameter" and one that just the column "Column 1". I call this other table "Other Table".
Now create a measure in "Other Table" like so:
Measure = SUMX( 'Other Table' ,'Other Table'[Column 1] * [Parameter Value] )
The measure [Parameter Value] is automatically created when you create the What If Parameter.
Hopefully, this is what you are looking for,
Regards,
Tom
Hey Tom,
Thank you for your answer. I tried your solution but it is not completely what my data needs.
My "Column1' values have some specific characteristics for why this is not working. It is also categorized, for which the values in each categorie should not add up. This is how the data looks like:
Number | Buildings | Value risk |
1 | 67 | 1,40E-006 |
1 | 69 | 0,00E+00 |
1 | 91 | 1,08E-004 |
1 | 94 | 8,09E-005 |
2 | 67 | 1,40E-006 |
2 | 69 | 0,00E+00 |
2 | 91 | 1,08E-004 |
2 | 94 | 8,09E-005 |
3 | 67 | 1,40E-006 |
3 | 69 | 0,00E+00 |
3 | 91 | 1,08E-004 |
3 | 94 | 8,09E-005 |
So the category is building, with buildings 67, 69, 91 and 94. For each building, there is a number from 1 until 10. It is this number that I'd like to multiply (so this is "Column 1"), by multiplying it by a WhatIfParameter.
I think by using the SUM function, the values for number 1 of all the buildings are getting summed up.
The reason I want to keep the 4 building seperated is for making a line chart afterwards.
What I am doing now is making a line chart with a line for each of the buildings, with the value risk plotted and the Number on the X-axes. This gives me 4 different lines on the line chart. Now I'd like the X-axes (so "Number") multiplied by the WhatIfParameter, keeping the Value Risk the same for each value line.
When I use the measure created by your solution presented, I only get 1 line on the line chart.
User | Count |
---|---|
80 | |
78 | |
37 | |
34 | |
31 |
User | Count |
---|---|
93 | |
81 | |
60 | |
49 | |
49 |