Replaces the existing text with a new text in a text string.
SUBSTITUTE (<text>, <old_text>, <new_text>, <instance_num>)
|Sr.No.||Parameter & Description|
The text in which you want to substitute the existing text with a new text, or a reference to a column containing text.
The existing text that you want to replace.
The text you want to replace old_text with.
The occurrence of old_text you want to replace.
If omitted, every instance of old_text is replaced.
A string of text.
SUBSTITUTE function is case-sensitive. If the case does not match between find_text and old_text, SUBSTITUTE will not replace the text.
If find_text is “Not” and within_text contains “not”, SUBSTITUTE will not replace the text.
DAX SUBSTITUTE function is similar to DAX REPLACE function.
You can use SUBSTITUTE function if you want to replace the specific text in a text string.
You can use REPLACE function, if you want to replace any text of variable length that occurs at a specific position in a text string.
replaces all instances of “Powder” with “Lotion” in the Product column. If “Powder” is not found in any of the rows of the Product column, nothing is changed.
26 Lectures 4.5 hours