Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
Not applicable

How to calculate total count of a specific value in a field?

Hi All,

I am trying to calculate the count of a specific value in a field. I would like a table with 'Topic,' and when i pick a specific topic I am able to get a total count from a Yes/No field 'Validation.'  For example: Topic = documents and the validation has 24 docments have YES and 6 NO.  How can I get it to show the total YES/NO count based on criteria I pick?  I currently have my Dimension = Topic, Expression = count(distinct(validation).

Thank you for your help.

1 Solution

Accepted Solutions
Not applicable

Re: How to calculate total count of a specific value in a field?

Looks like my image didn't come across. Here you go:

QVCommunity.JPG

8 Replies
MVP
MVP

Re: How to calculate total count of a specific value in a field?

Hi

You will need something like

     Count({<Validation = {'yes'}>} Validation}

     or

     Sum({<Validation = {'yes'}>} 1}

Hope the helps

Jonathan

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
MVP
MVP

Re: How to calculate total count of a specific value in a field?

Remember that QV field names are case-sensitive - validation <> Validation

Logic will get you from a to b. Imagination will take you everywhere. - A Einstein
Not applicable

Re: How to calculate total count of a specific value in a field?

That does work, thank you.  How can I take it one step further so that when I pick a topic, say "Large reports," it will show me that out of 20 Topics, there are 10 large reports and 'x' are yes and 'x' are No validations?

Not applicable

Re: How to calculate total count of a specific value in a field?

I would suggest building a Straight Table Chart with your 'Validation' field as the Dimension and Count(Validation) as the expression. This will look something like this:

QVCommunity.JPG

Not applicable

Re: How to calculate total count of a specific value in a field?

Looks like my image didn't come across. Here you go:

QVCommunity.JPG

Not applicable

Re: How to calculate total count of a specific value in a field?

Thank you for your response. I have done the validation table, but when I click on a specific Topic, the table does not change.  It continues to show the total of the count of all validations.  I though it would adjust as you dive deeper into specifics.

Not applicable

Re: How to calculate total count of a specific value in a field?

Hey, I figured out the problem.  The key field in which i was connecting too was somehow not allowing it to link correctly. The the working formula was Count({<Validation = {'yes'}>} Validation}. Thanks Jonathan and  Rebeccad.

diwaskarki
Contributor

Re: How to calculate total count of a specific value in a field?

how can I do this in a pie chart?

Community Browser