The selectedvalue() has perhaps a bit misleading name, but these two expressions are equivalent
SELECTEDVALUE( <columnName>, <alternateResult>)
IF(HASONEVALUE(<columnName>), VALUES(<columnName>), <alternateResult>)
If the filter context has narrowed the values in the column down one unique value, this value is returned, otherwise a blank or alternative value is returned: https://dax.guide/selectedvalue/
If column 1 is a flag value, and not something you will add in a report the SUMX-version is probably what will give you what you need.