Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 ilanbaruch
		
			ilanbaruch
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		hi all
trying to calculate previous three months from user selection i.e
if the user selected 201804 the expression should retrieve calculation for : 201804,201803,201802
tried it with :
SUM({<YYYYMM={"$(='>=' & date(AddMonths(max(FULL_DATE),-3),'YYYYMM'))"},MM=,YYYY=>}AMOUNT)
but it retrieves 0 , (not the actual result)
any ideas?
advanced thanks
 
					
				
		
 arvind_patil
		
			arvind_patil
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi ilan,
Please try below highlighted :
SUM({<YYYYMM={"$(='<=' & date(AddMonths(max(FULL_DATE)),'YYYYMM'))"},MM=,YYYY=>}AMOUNT)
YYYYMM={"<=$(=AddMonths(Max(YYYYMM)))>=$(=AddMonths(Max(YYYYMM),-3))"}
Thanks,
Arvind Patil
 
					
				
		
 arvind_patil
		
			arvind_patil
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi ilan,
Please try below highlighted :
SUM({<YYYYMM={"$(='<=' & date(AddMonths(max(FULL_DATE)),'YYYYMM'))"},MM=,YYYY=>}AMOUNT)
YYYYMM={"<=$(=AddMonths(Max(YYYYMM)))>=$(=AddMonths(Max(YYYYMM),-3))"}
Thanks,
Arvind Patil
 ilanbaruch
		
			ilanbaruch
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		thank you very much,
below my final expression :
YYYYMM={"<=$(=AddMonths(Max(YYYYMM),0))>=$(=AddMonths(Max(YYYYMM),-3))"}
 
					
				
		
 arvind_patil
		
			arvind_patil
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Welcome
Thanks,
Arvind Patil
