Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
 
					
				
		
Hi All,
I want to achieve the foll: with set analysis
count of id where field a<> field b
i tried '<>' and '-='.
But, both did not work.
Please help me out.
Thanks,
Anju
 
					
				
		
 cn_sa_dev
		
			cn_sa_dev
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		i.e.
=
(count({<MPCS_WLDTI={'1','0'}, SDP_WLDTI={'1','0'},MER_MATCH_MASK={'3'},RUN_DATE = {'$(vMaxDate)'}>
- <MPCS_WLDTI={'1'}, SDP_WLDTI={'1'},MER_MATCH_MASK={'3'},RUN_DATE = {'$(vMaxDate)'}>
- <MPCS_WLDTI={'0'}, SDP_WLDTI={'0'},MER_MATCH_MASK={'3'},RUN_DATE = {'$(vMaxDate)'}>} distinct MTR_ID)
)
 
					
				
		
 mjm
		
			mjm
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hello Anju,
Can you please provide a full example of the set analysis statement which you are using? What exactly is it you are trying to achieve with this Set Analysis statement?
 
					
				
		
=COUNT({1<A<>B>}ID)
something like this.. but the syntax is wrong...
 
					
				
		
I would rather do
count({$ or 1 <A = {"A<>B"} >} ID)
Fabrice
 kaushalview
		
			kaushalview
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi,
Use syntax -= in set analysis and without set analysis expression <>
Example:
Count({<Country-={'U.S'}>})
Regards
Kaushal Mehta
 Clever_Anjos
		
			Clever_Anjos
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Maybe this can solve your need
=COUNT({<A=A-P(B)>}ID)
 
					
				
		
 israrkhan
		
			israrkhan
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		try
if(A<>B, Count(ID))
and make sure , The Field Name are In same Caps, if You have field in Database like small a, and you use Capital A in set analysis,i will not work, qlikview is case sensitive...
 
					
				
		
 cn_sa_dev
		
			cn_sa_dev
		
		
		
		
		
		
		
		
	
			
		
		
			
					
		Hi Anju,
"-=" Does work for "not equal to" despite showing a syntax error. It will underline the statement in red, but the top of the Edit Expression bar will still read "Expression Ok" and it will return the correct data.
Regards,
Chris
 
					
				
		
Hi Chris,
I tried this
=COUNT({1<MER_MATCH_MASK={'3'},RUN_DATE = {'$(vMaxDate)'},MPCS_WLDTI-=SDP_WLDTI>}MTR_ID)
it shows a red line under mtr_id , but returns the wrong answer..
it returns the answer satisfying only conditions for mer_match_mask & run_date and
ignores mpcs_wldti
 
					
				
		
Hi,
I tried this.But it did not work.
=COUNT({<MPCS_WLDTI=MPCS_WLDTI-P(SDP_WLDTI)}>}MTR_ID)
