Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
danosoft
Specialist
Specialist

Filter distinct Count() for only a condition

Hi i need to filter my Count() only when a condition is verified, in details:

count.png

i need to Count, only items where my field ANNO_EMI = ANNO + 1

28 Replies
arvind_patil
Partner - Specialist III
Partner - Specialist III

Hi Daniele,

may be like this:

Count (Distinct {<ANNO_EMI ={'ANNO + 1'}>} PDR)


Thanks,

Arvind Patil

danosoft
Specialist
Specialist
Author

I think there are an error becouse if i write like this it not show me nothing but if i write:

Count (Distinct {<ANNO_EMI ={'04'}>} PDR)


it show me the line..... i think the error is in the field ANNO + 1

sunny_talwar

May be this

Count(DISTINCT {<ANNO_EMI = {"$(=Num(ANNO+1, '00'))"}>} PDR)

danosoft
Specialist
Specialist
Author

No, i think problem is in the Field ANNO, the formula not take it, becouse is i write :

Count(DISTINCT {<MESE_EMISSIONE = {"$(=Num(2+1, '00'))"}>} PDR)

it take me the value and design the line in the chart

sunny_talwar

May be there are multiple values and you need to use Max() or Min() function

Count(DISTINCT {<ANNO_EMI = {"$(=Num(Max(ANNO)+1, '00'))"}>} PDR)

danosoft
Specialist
Specialist
Author

graphann.png

Look at the picture, it not show me nothing..... my field MESE_EMISSIONE is in my database with value format 01... 12 and MESE_COMPETENZA with the same format.... if i use that kind of formula with replace MESE_COMPETENZA with  a number value, chart show me values

Count(DISTINCT {<MESE_EMISSIONE = {"$(=Num(2+1, '00'))"}>} PDR)

sunny_talwar

What do you get when you add this to a text box object?

=Num(Max(ANNO)+1, '00')

Do you get 03?

danosoft
Specialist
Specialist
Author

I get all these values, like you see in the line chart

MESE.png

sunny_talwar

I was asking for this expression in a text box object, not a line chart?