
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Count on if condition
Please refer the table below:
I want an expression to count number if all the values design_accept=3.
Eg; If all the values for design_accept=3 for each MachDateKey then it should count as 1.
Please assist.
- « Previous Replies
-
- 1
- 2
- Next Replies »
Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How about this
Count({<MachDateKey = {"=design_accept = 3"}>} DISTINCT MachDateKey)


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Mohammed,
Your expression like below:
Count({<design_accept={'3'}>}MachDateKey)
Thanks,
Arvind Patil

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi Arvind,
I am unable to get the desired result with the above expression.
I am aware of this expression and have used it already (Count({<design_accept={'3'}>} distinct MachDateKey) ) but even though sometimes not all values are equal to 3 , it is taking count for that MachDateKey.
So I need some count function which includes avg expression inside IF condition.


- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
O Got it.
write it on script level:
if(match (design_accept,'3') and not is null(MachDateKey) ,1,0) as Count3rd,
And in front end expression :
count (distinct Count3rd)
Thanks,
Arvind Patil

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Not working..
Syntax error I guess

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
How about this
Count({<MachDateKey = {"=design_accept = 3"}>} DISTINCT MachDateKey)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi nMohammed, you can try with:
=Count(DISTINCT {<MachDateKey{"=Max(design_accept)=3 and Min(design_accept)=3"}>} MachDateKey)

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you all for the help...

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What changes do i need to write in the above set analysis expressions if I bring in one more field called "Date" which has only two unique values ?
Assume max date and min date.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Not sure I understand, what do you mean 2 unique values for the Date field? Can you elaborate with an example?

- « Previous Replies
-
- 1
- 2
- Next Replies »