Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
 upaliwije
		
			upaliwije
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi Friends
I have created a variable to be used in my expression but it does not work. Kindly help me to get it corrected
 anushree1
		
			anushree1
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		please check the attached I added a new Expression called Using Variable New Expression in the chart using Variable and removed equals from variable definition
 Shubham_Deshmuk
		
			Shubham_DeshmukHi @upaliwije,
1. It is not good practice to put such hard code values of month year
2. If you want so, no need to use variable for that
3. Try this
=count(DISTINCT(if(match(CHARGED_Month_Year,'Aug-2018','Sep-2018',,,,,),CLAIM_NO)))
 
					
				
		
 upaliwije
		
			upaliwije
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Thanks
Since I have to use this variable over & over again I thought of creating a variable
 Shubham_Deshmuk
		
			Shubham_Deshmuk 
					
				
		
 upaliwije
		
			upaliwije
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		What you suggest works. In fact my previous expression shown in my image also works fine . But What I want to use the expression with a variable for the months mentioned. If you can pls help me with that. Thanks
 MindaugasBacius
		
			MindaugasBacius
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Try modifying the expression like this:
Count(Distinct {<CHARGED_month_year = { '$( =$(vCM) )'} CLAIM_NO)
 Shubham_Deshmuk
		
			Shubham_Deshmuk
Hi,
First load you month-year data as it is fix,
dates:
LOAD * INLINE [
monthYear
Aug-18
Sep-18
Dec-18
];
monthYearCombo:
load Concat( chr(39) & monthYear& chr(39), ',') as monthYearCombo
Resident dates;
Let vStatus=monthYearCombo;
Now in expression use this,
=count(DISTINCT(if(WildMatch(CHANGED_Month_Year,'*$(vStatus)*'),CLAIM_NO)))
 Shubham_Deshmuk
		
			Shubham_Deshmuk anushree1
		
			anushree1
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		remove Charged_Month_Year from variable definition keep it as : ={'Aug-2018',.......}
 
					
				
		
 upaliwije
		
			upaliwije
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Thanks
Still it is not working
