what if parameters
8 TopicsHow to input any value into Numeric Parameter Field
Hi Everyone, Is inputting any value into the Numeric Parameter Field in Power Bi possible? For instance, please see the following: 1) Modelling Tab > New parameter I click on the modelling tab and create a new parameter. 2) Click on Numeric Range 3) Increase the Maximum number to whatever I please ( and decrease the minimum if I choose) 4) Error occurs I select 500 and it outputs 495. The problem is explained here: https://whatthefact.bi/power-bi/data-model/why-is-it-sometimes-not-possible-to-select-the-exact-number-in-the-what-if-parameter-and-how-can-this-be-solved/ However, I need a solution to be able to pick any value within any range without the number messing up!Solved2.5KViews0likes2CommentsGet value of second table based on multiple conditions
Hi, I have two tabels. One with historic values of an asset and one with asset purchases. I want to get the historic values of the asset purchases based on a what if parameter preferably using a measure. For example if the what if parameter is 5 i would like to get the historic value 5 days earlier. Sometimes there won't be a historic value that specific date and then i would like to get the value of the first date before that date (for example 6 days earlier). Below are the structure of the tables. Historic values table: Asset ID Date Price Asset purchases table: Asset ID Transaction date PriceSolved651Views0likes2CommentsWhat-if parameter : Visuals are not changing according to the parameter changes (using slicer)
I added a What-if parameter to my Power BI report and it generated a table and a measure. Using that measure I did a calculation as given below: Backup gen qty with powercut hrs = MainTable[Fuel per Hour] * 'power cut hours'[power cut hours Value] In here 'power cut hours'[power cut hours Value] is the measure created when adding What-if parameter. But the selected value from the slicer does not change the output in my above calculation, it just only give a blank and as a result visuals are not changing either. Please kindly give a solutionn for this.1.1KViews0likes2CommentsCAGR HELP! Forecasting using Current data
I literally forgot how to do this, please help. I have a table that has 2018-2022 Year sales. I created a whatifparameter from 0-100% to be the CAGR value. Focusing only on 2022 sales, I want the user to be able to select their desired CAGR % and see what the how it impacts 2023-2025 forecasted sales. Forecasted Sales is dax table using Union Row...example belowSolved1KViews0likes1Commentwhat if scenarios with complex filtering
Hi everyone, I am setting up a scenario-testing with what if parameters. My modelling is related to school performance in certain fields to which multiple schools can contribute. I would like to be able to calculate measures based on user selection of parameters and schools, while keeping all other values constant. My fact table is like the below: Author PublicationID Citations BJ A 10 GT A 10 GT B 5 GT C 3 SR A 10 SR C 3 SR D 0 And my dim table is the following: Author School BJ School of Business GT School of Medicine SR School of Medicine One publication can belong to many authors and schools, authors & schools can have many publications and schools can have many authors. (This is a simplified version of my model because I also have other dim tables and publicationIDs can belong to various fields. ) I want to calculate distinct count and other measures of publicationsIDs belonging to NON SELECTED schools. How can I count the publicationIDs where none of the authors belong to the selected school(s)? If I am calculating the number of PublicationIDs belonging to non-selected schools with the measure below publications that belong to both selected and non-selected schools are counted in, so this gives me an incorrect result: PubIDs of nonselected = CALCULATE(DISTINCTCOUNT(my fact table'[PubID]), EXCEPT(ALL(my dim table[School]),ALLSELECTED(my dim table[School]))) Another failed solution: I have tried setting up a calculatedtable first to isolate the publicationIDs of selected school(s): IDsofselected = CALCULATETABLE(VALUES('my fact table'[PubID])) And then I've tried many ways to get the IDS that are all other IDs except the ones in this table. I experimented with EXCEPT&CALCULATETABLE, CROSSFILTER, TREATAS and creating a duplicate of the fact table to get the distinct count of publicationIDs belonging to NON SELECTED schools excluding those which also belong to selected schools. Any help is greatly appreciated.Solved847Views0likes2CommentsVariable Value - What if Parameter not showing/calculating as entered.
I have a view with a couple what if parameters includeds. The Service fees as shown is working just fine, but when I swtich to an entry view for the manual price I can't get it to react to exactly what I'm entering as the value. In this case I tried to enter 3.24 and as you can see with the criteria below that value would be on the created table. But the visual just jumps to what's shown here. Similar if I try an enter 7.25 for a moment it will show 7.99999999 and then when I click away it will push to 8.00. If there any other walk throughs I'm missing or views on what I'm doing wrong with this method of trying to enter a direct figure/value? Manual Price = GENERATESERIES(0.00 , 299.99 , 0.01 )1.5KViews0likes3CommentsUsing what-if parameters (instead of bookmarks)
Hi all, hope all of you are doing fine 🙂 I have been working with PBI for some time and also some tasks with what of parameters, but only used what-if parameters in very simple examples. Now I would like to use parameter instead of my bookmarks.. So for now I have report looking something like this: So I have a bar chart and on the left I have three bookmarks depending on what should be in the legend of the bar chart. So for example when I have selected Split by name: a bar chart which has in the legend a column "name". When I click on split by month the legend will be based on the column "Month" etc... However, as I have also some other bookmarks in my original repor, it creats a bit confusing look, so I would like to create this possibility with what if parameter: Instead of the bookmarks I would like to have a slicer that is offering these 3 options. These 3 field are original variables from my dataset (so no calculated columns). So what I have done so far is I created a parameter: Parameter = GENERATESERIES(1, 3, 1) which then includes also measure: Parameter Value = SELECTEDVALUE('Parameter'[Parameter]) and I created a calculated column to match 1,2,3 number to my desired outputs so: name, month and order: Split by = IF('Parameter'[Parameter] = 1, "Name", IF('Parameter'[Parameter]=2, "Month", IF('Parameter'[Parameter]=3, "Order"))) and now, I am strugelling how to use these fields in my report, so it becoms functioning. Normally I would use the parameter value in measure that I am using in the Value field in bar chart, but here the values are staying the same over the different views, just the legend should change based on the selected parameter. Can anybody help me with this? 🙂Solved2.3KViews0likes4CommentsI have to create a column in a table, whose value will be selected values from what if parameter
I have a Table1 and in that I need to create a custom column, whose value will be selected value from the 'what if' paramter I tried to create a Parameter Value column, by using the dax Parameter Value = SELECTEDVALUE(Parameter[Parameter]) But I am getting blank in that column. Can anyone please help me in resolving this issue. Thanks in advance1.3KViews0likes3Comments