Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
 vinod2086
		
			vinod2086
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi ,
I have a requirement as below. when i select single id it should take Target Site and when i select Multiple id's it will take Target Aggr.
i have used mentioned exp
=If(Count([Id])=1,Only(Site_Target),Only(Aggr_Target))
here everything is fine but target Aggr i need to exclude '= ' and '%' (user dont want to see = and % like insted of =0% i need to display 0, 100,95 so on)
how to write condition.
| Target Site | Target Aggr | 
|---|---|
| 0 | =0% | 
| 0 | =100% | 
| 0 | =100% | 
| 0 | =100% | 
| 1 | >=95% | 
| 1 | >=95% | 
expected output
if it is =0% o/p is 0
=100% o/p is 1
>=95% o/p is >=95
 prma7799
		
			prma7799
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Try like this
=PurgeChar('Aggr_Target','>=%')
 
					
				
		
 marcus_sommer
		
			marcus_sommer
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Maybe with: keepchar(Only(Aggr_Target), '0123456789')
- Marcus
 its_anandrjs
		
			its_anandrjs
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		You can use mapping table for this and map with decimal values with its corresponding value and if not found in applymap then use the Null() to fill null value there.
MapTab1:
Mapping Load * Inline
[
Target Aggr, Decimal Value
0%,0
=100%,1
>=95%,0.95
..
..
..
];
Fact:
Load
Applyname('MapTab1',[Target Aggr],Null())
 qlik4asif
		
			qlik4asif
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		HI Vinod,
You can give as PurgeChar('Aggr_Target','=%')
It will omit = and % and give only the values.
If the issue is solved pls mark it as solved
Thanks
Asif
 its_anandrjs
		
			its_anandrjs
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Another approach is KeepChar at script and UI level
Load *,
KeepChar([Target Aggr],'0123456789%') as [Decimal Value],
From .....
Ex:-
Load *,
KeepChar([Target Aggr],'0123456789%') as [Decimal Value] Inline
[
Target Aggr
0%
=100%
>=95%
];
