Forum Discussion

niteshtrehan89's avatar
niteshtrehan89
Helper III
1 year ago
Solved

Multiple value was supplied where a single value was expected error

Hi All, 

 

I have two tables with me. One is Actual and other is Budget.  I did the append for the two tables using the union and summarize DAX function. 

I am using the Matrix Visual and created the below measure for the same.

When i am expanding it using the + in the matrix visual, then it is showing me the below error message.

 

need a solution that it should run using the + sign in the matrix visual.

  • Hi niteshtrehan89 ,

     

    You cannot use the VALUES and then a = with a single value you need to redo all your syntax to:

     

    SELECTEDVALUE(Summary[Header]) = "Asset Avg Balance" && SELECTEDVALUE(Summary[MIS Value]) = "YTD Budget"

     

     

  • Hi niteshtrehan89 ,

    The issue lies with the VALUES function. It returns a list of distinct values, which can be used for counting, filtering, or summing, but it doesn't provide a single value. In your IF function logic, a single value is expected to evaluate the conditions. I recommend replacing the VALUES function with the SELECTEDVALUE function, which returns a single value if one exists, or BLANK otherwise.

     

    I hope this helps! If it does, please mark it as a solution and consider giving a Kudos.

     

    You can learn more about VALUES function here 

    Thank you!

2 Replies

  • Hi niteshtrehan89 ,

     

    You cannot use the VALUES and then a = with a single value you need to redo all your syntax to:

     

    SELECTEDVALUE(Summary[Header]) = "Asset Avg Balance" && SELECTEDVALUE(Summary[MIS Value]) = "YTD Budget"

     

     

  • Hi niteshtrehan89 ,

    The issue lies with the VALUES function. It returns a list of distinct values, which can be used for counting, filtering, or summing, but it doesn't provide a single value. In your IF function logic, a single value is expected to evaluate the conditions. I recommend replacing the VALUES function with the SELECTEDVALUE function, which returns a single value if one exists, or BLANK otherwise.

     

    I hope this helps! If it does, please mark it as a solution and consider giving a Kudos.

     

    You can learn more about VALUES function here 

    Thank you!