Macki
Macki

Reputation: 31

multiple use of substitute function but it should combine the results in one column and cell

please check the picture link to understand the query **

I want to combine the multiple raw into one text string , I can use substitute function to change one word in a text string but how can i use the same function to change multiple text in the same raw ? Please check the below picture

Raw 4 is a old text and i want to change three word of that raw and results should be like last raw, I guess picture is pretty clear to understand this.

I would appreciate if anyone can help in this , Please check the below picture

http://3.bp.blogspot.com/-239FYyB8zC8/UY1dJC9eU7I/AAAAAAAAAU0/XlfBWN0k9Ts/s1600/Excel.jpg

https://i.sstatic.net/8RmS2.jpg

Upvotes: 2

Views: 24585

Answers (1)

Daniel Möller
Daniel Möller

Reputation: 86600

Use the substitute inside another substitute inside another substitute.

Should look like:

= substitute(substitute(substitute(text; oldtext; newtext); oldtext2; newtext2); oldtext3; newtext3)

In your specific case:

 = substitute(substitute(substitute(D2; "ABC"; A2); "DEF"; B2); "JKL"; C2)

Upvotes: 5

Related Questions