Count Distinct Over If

Hi Everyone,

I have a need to do a count distinct over if. Unfortunately there’s no function for this, QS issues an error when I try to combine functions. The formula looks like this, but I need to replace avgOver with distinct count. Anyone have any ideas?

avgOver(

ifelse(${CurPlan}={Name (Plan)} AND ${CompElement2}=‘Base’,{Base MRP (CompositeValue)},NULL),[{Name (Plan)},{Name (Paymarket)},{Job Code (CompanyJob)}],PRE_AGG)

Thanks,
Keith

Hi @keith.fortier

You can do distinct count over. This is your go to resource for this question.

Regards,
Giri

2 Likes

Hi @keith.fortier

It’s been a while since we last heard from you. If you have any further questions, please let us know how we can assist you.

If we don’t hear back within the next 3 business days, we’ll proceed with close/archive this topic.

Thank you!

Hi @keith.fortier

Since we have not heard back from you, I’ll go ahead and close/archive this topic. However, if you have any additional questions, feel free to create a new topic in the community and link this discussion for relevant information.

Thank you!