How to Use COMBINEVALUES function in DAX

How to Use COMBINEVALUES function in DAX

If you want to combine multiple values in DAX, the COMBINEVALUES function is what you need. This function concatenates a list of strings separated by a delimiter. The result is a single string.

COMBINEVALUES(<delimiter>, <string1>, <string2>[, <string..>]…)

• String1: The first string that you want to concatenate.
• String2: The second string that you want to concatenate.
• Additional strings that you want to concatenate. There can be up to 30 strings in total.
• Delimiter: The character that will be used to separate the concatenated strings. This can be any character, including a space, comma, or semicolon.

How do I combine 3 columns in DAX?

When you have data in multiple columns and want to combine it into a single column, you can use the COMBINEVALUES function. This DAX function concatenates values from multiple columns into a single string.

To use the COMBINEVALUES function, you need to specify the values you want to combine and then set a delimiter that will separate the values in the output string. For example, if you have data in three columns named FirstName, LastName, and Location, you could use the following formula to combine the values into a single string:

Output = COMBINEVALUES(" ",'Table'[FirstName],'Table'[LastName],'Table'[Location])
How to Use COMBINEVALUES function in DAX

Combinevalues vs. concatenate functions in DAX.

When working with DAX, you may encounter the COMBINEVALUES and CONCATENATE functions. Both of these functions can be used to combine values from multiple columns into a single column. However, you should be aware of some critical differences between these two functions.

The COMBINEVALUES function will combine all the values from the specified columns into a single column, with each value separated by a delimiter (defined by the user).

The CONCATENATE function will also combine all of the values from the specified columns into a single column. However, unlike COMBINEVALUES, it will not use a delimiter to separate the values.

To learn more, please visit Learn DAX

Similar Posts