SelectedValues, Values and What-If

My question is based on what is the difference between creating a slicer selections using either selectedvalues, values or using what-if parameters. See below example

Date Range example
looking at the above image if i want to slice it using selectetions i can use either selectedvalues or values and produces the same result.

Time Frame selected = SELECTEDVALUE( ‘Date Ranges’[Day], 360 ) or using values

Time Frame Selected = VALUES( ’ Date Ranges’[Day] ) Values

These two produces a similar result

On the other if i were to use what if parameter the end result is a measure that will be created that uses SELECTEDVALUES.

My question therefore centers on what is the difference between these two SELECTEDVALUES AND VALUES when it comes to slicers, is it performance issues or matter of preference?

You are correct in stating that when a single selection is made there is no difference in the result. However when multiple- or no selection is made then they behave differently.
.
SELECTEDVALUE ( <columnName>, <alternateResult> )

Is the same as:

IF ( HASONEVALUE ( <columnName> ) , VALUES ( <columnName> ) , <alternateResult> )
.
Also check out this video by Sam.

I hope this is helpful.

1 Like

Hi @Damsky, we’ve noticed that no response has been received from you since the 21st of April. We just want to check if you still need further help with this post? In case there won’t be any activity on it in the next few days, we’ll be tagging this post as Solved. If you have a follow question or concern related to this topic, please remove the Solution tag first by clicking the three dots beside Reply and then untick the checkbox. Thanks!