cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple replacements in text string - how to fix in expression editor?

Former Member
0 Kudos

I want to be able to search a user database of Norwegian and Swedish users. Both languages have special characters, and the same name in Sweden and Norway could be written Björn in Swedish and Bjørn in Norwegian. I thus want the search field to send bj*rn to get both variants of the name.

This I can manage with REPLACE(@TEXT,'ø','*') in the Expression editor. BUT then I would have to check for both the Swedish and the Norwegian variants and in small and capital letters ie: ø,Ø,öÖ.

How do I do a multiple replace in a text string through the expression editor to get all variants:

REPLACE(@TEXT,'ø','*')

REPLACE(@TEXT,'ö,'*')

REPLACE(@TEXT,'Ø,'*')

REPLACE(@TEXT,'Ö,'*')

to be applied to the same text string?

Henning

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

I don't know how to do that in the VC, but I would try to have the database handle this.

Former Member
0 Kudos

Fixed it: REPLACE((REPLACE((REPLACE((REPLACE(@FSTNAME_M,'Ö','')),'ö','')),'Ø','')),'ø','')

Henning