# QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Join us for a live Q&A! September 21, 10 AM ET - Onboarding Fast in Qlik Sense SaaS! REGISTER
cancel
Showing results for
Did you mean:
Contributor

## Unique count from three different Fields

Dear all,

I need to have the distinct count of three different field (let's say field A, B and C) in one expression.

I know the distinct count of two fields (A and B) in one expression is the following:
=Count(Distinct A) + Count({<B -= p(A) >}Distinct B)

I tried the following for the three field counter:
Count(Distinct A) + count({<B-= p(A)>}distinct B) + count({<C-= p(A)>}distinct C)

Unfortunately, it doesn't work.

Could you help me out? Thanks in advance!

Labels (3)

• ### P function

1 Solution

Accepted Solutions
MVP

May be this

``=Count(DISTINCT A) + Count({<B -= p(A) >}DISTINCT B) + Count({<C-= p(A)+p(B)>} DISTINCT C)``

2 Replies
MVP

May be this

``=Count(DISTINCT A) + Count({<B -= p(A) >}DISTINCT B) + Count({<C-= p(A)+p(B)>} DISTINCT C)``

Support (Former)

Roland, did Sunny's post help you get what you needed?  If so, please be sure to return to the thread and use the Accept as Solution button on his post to give him credit for the assistance and to let other Community Members know this worked for you.  If you still need further help, please leave an update.

Regards,
Brett

To help users find verified answers, please do not forget to use the "Accept as Solution" button on any post(s) that helped you resolve your problem or question.
I now work a compressed schedule, Tuesday, Wednesday and Thursday, so those will be the days I will reply to any follow-up posts.
Community Browser