Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 anuradhaa
		
			anuradhaa
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		I want to get count when data is there,
So i use below expression
if(len(Date)<0,Count(Date)).
But it doesn't give any value.
if i use only count(Date) it return values. what was my issue
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		 
					
				
		
Maybe try something like this :
Count( if ( len(Date)>0 , 1 , 0 )
 sunny_talwar
		
			sunny_talwar
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		May be this using set analysis:
Count({<Date = {'*'}>} Date)
 
					
				
		
 avinashelite
		
			avinashelite
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Try like this
if(len(trim(Date))>0,Count(Date))
 tresesco
		
			tresesco
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		You probably meant,  Sum( if ( len(Date)>0 , 1 , 0 ). Otherwise, counting '0' (when the condition fails) also increases the count. 
 
					
				
		
may be something like this?
=Count(if(len(trim(Date))>0,Date))
You can use Disticnt, if required?
 
					
				
		
 jagan
		
			jagan
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi,
You can simply use
Count({<Date = {'*'}>} Date)
* ignores Null & Empty values.
If you want to deal this in script then try like below
LOAD
*,
If(Len(Trim(Date)) >0, 1, 0) AS DateCount
FROM DataSource;
Now in Front end just use
Sum(DateCount)
Hope this helps you.
Regards,
Jagan.
