The CONCATENATE function joins two text strings into one.
CONCATENATE(
text1,
text2
)
- text1: First text string to join or name of the column that contains the first text strings to join.
- text2: Second text string to join or name of the column that contains the second text strings to join (this text string will be displayed to the right of text1 in the returned text).
The CONCATENATE function returns a text string.
In practice, both text1 and text2 can be values of any type, because if any of the arguments is not a text (it is a Boolean, a time or a date), it will be converted to text.
Unlike the CONCATENATE function in Excel (which supports up to 254 arguments), the DAX function only supports two arguments. If you want to concatenate more than two strings, the easiest thing to do is use the concatenation operator (&) -see an example later-.
If, instead of using a column reference as an argument, you want to insert the text string directly into the function, it must be enclosed in double quotes.
The following example concatenates the country name and postal code to create a field that uniquely represents each geographic area:
In this second example, the concatenation operator (&) is used to concatenate the same fields -country name and postal code- adding, between both fields, a hyphen and a blank space before and after it: