Discussion Board for collaboration on QlikView Scripting.
I have a name field and I want i to keep the same number of chacters but replace everything with '*' except for the first character.
Name = 'Smith' - Encrypted Name = 'S***'
Name = 'Johnson' - Encrypted name = J******
Is there any script that will do this?
Go to Solution.
Left(Name,1) & repeat('*', len(Name)-1) as Name
As a further q is there any way I can put the last character on there aswell
modify Gysbert's expression to do it:
Left(Name,1) & repeat('*', len(Name)-2) & right(Name,1) as Name
It's better define a maximum size: (in this case 60)
Left(Name,1) & repeat('*', 58) & right(Name,1) as Name