Forum Discussion
DAX Selectvalue() does not work with Dynamic Calculation Columns
Hello,
I'm new to power BI.
I have created table "Units" that has two choices (below). This is used in a Slicer.
| Selected Units | Choice |
| Acre-Feet | 1 |
| Million Galons | 2 |
I have a measure with formula: Units Value = LOOKUPVALUE(Units[Choice],Units[Select Units], SELECTEDVALUE(Units[Select Units],"Million Gallons"))
The information for the measure displays correctly on the Card.
I have another table "Volumes" with volumes and various units for volumes. I want to allow the user to choose one unit type from "Units" table for the report display. I added a New Column to the "Volumes" table with the formula:
2 Replies
- Greg_DecklerCommunity Champion
Columns are not dynamic, they are calculated at data load so they cannot change when you change a slicer. You need a measure.
- SsibbettFrequent Visitor
If I put the column formula in a measure, the measure will not calculate values for each row.
Here is my column formula Volumn UOM = SWITCH(Units[Units Value],1,[To AF]*[Volume],2,[To MG]*[Volume],0). How do I make this into a measure?