Forum Discussion
CountIF based on grouping ID
are you saying you want to calculate the rows where these 2 events are present?
measure = calculate(countrows(table), Event = "Trigger 1" || Event = "Trigger 2")
No Sorry, for the confusion, they are two seperate columns in the above example.
I want to group all the event ids together, and calculate how many events where the event rows contain two inputs.
- vanessafvg9 years agoCommunity Champion
kirwanm1 well if you using a visual where you place the event on it and then have a measure like
measure = distinctcount(column) on the trigger column that should give you a distinct count of triggers per event, when you place those 2 fields you will get the event with the unique count of triggers
unless you want to do a count of all events, are the triggers duplicated per event? and if so are you wanting to know that?
- kirwanm19 years agoFrequent Visitor
No thats not it. I need to group based on the first column.
ID Event1 Yes
1 No
1 Maybe
2 Yes
2 Yes
2 No
3 Maybe
3 Yes
3 No
So that is the table above. I need a distinctcount of the ID above which would be three 3. Filtered to only include if the Event contains a No & Maybe, which would be 2 as id no.2 contains no maybes. Does this make sense?- vanessafvg9 years agoCommunity Champion
it does make sense yes, it sounds like you would get the result for each i.e maybe and then no and then merge where there is only both,i will have to think deeper on how to do it