Forum Discussion
Anonymous
7 years agoNot applicable
Most recent value by material by customer
Im trying to calculate my company's list prices by customer but, because our data isn't strictly a relational table (other sales info) many of these are repeated and depending on the date, the prices...
Anonymous
7 years agoNot applicable
It did work as a measure but I think I need it to be a calculated column. Thanks for all the help thus far this is sort of out of my depth haha
Cmcmahan
Resident Rockstar
7 years agoJust change the top to this:
VAR Customer = SELECTEDVALUE('Book for Promos'[BuyingGroupName])
VAR Material = SELECTEDVALUE('Book for Promos'[MaterialNo])
When you're creating a measure, any time you name a column, it comes back as the entire column of data (even if that column is only one row). SELECTEDVALUE([column]) gives you a single value of the first thing in the column.
When creating a calculated column, naming a column returns a single value, since DAX knows it's working with one point of data.