Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
Hi,
I am trying to replace below in script. But it is showing error
Replace(Lead,'Adam O'Balson','Adam O Balson') as Lead
Is there any wrong in above expression?
Thanks.
 
					
				
		
 stigchel
		
			stigchel
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		This should be working as you can see in the attached example, maybe there is something else wrong. What is the error? Otherwise please share a qvw which demonstrates the problem.
 
					
				
		
 stigchel
		
			stigchel
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Try With
=Replace(Lead,'Adam O'&Chr(39)&'Balson','Adam O Balson')
 
					
				
		
Thanks. tried this not working. Any solution please
 
					
				
		
 stigchel
		
			stigchel
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		This should be working as you can see in the attached example, maybe there is something else wrong. What is the error? Otherwise please share a qvw which demonstrates the problem.
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Why not try this instead:
=Replace(Lead, Chr(39), ' ')
Best,
Sunny
 PrashantSangle
		
			PrashantSangle
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi,
Use PurgeChar()
try like PurgeChar(FieldName,Chr(39))
Regards
 
					
				
		
Thanks. It's working now. How can I change the same expression if I want to keep 'Adam O'Balson'
I have one more requirement to use in pivot chart expression as below. when I am using this it is showing error
If(Match(Lead,'Mitchet','Sony', 'Adam O'Balson'),Lead)
 
 
					
				
		
 stigchel
		
			stigchel
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		It's the same problem as ' is used by qlikview as text delimiter. Same solution:
If(Match(Lead,'Mitchet','Sony', 'Adam O'&Chr(39)&'Balson'),Lead)
 
					
				
		
 jonathandienst
		
			jonathandienst
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		This works in 11.2 SR9 (two single apostrophes):
If(Match(Lead, 'Mitchet', 'Sony', 'Adam O''Balson'), Lead)
 
					
				
		
Thanks.
