# New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

Announcements
Qlik® Product Spotlight: Discover what’s possible. Get more from our products.
See for yourself. Register today.
Not applicable

## Qliksense Pie Chart: Excluding Null values

I have a pie chart showing the percentage of male/female answered our questionnaire, but there are some null values for some purposes, I tried to filter in the calculation field:

if([c-i-hh_gender]= Null() ,null(),count(KEY))

It didn't work for me.

P.S. I'm using Qliksense.

Tags (1)
1 Solution

Accepted Solutions
Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

Try this:

Count({<KEY = {"=Len(Trim([c-i-hh_gender])) = 0"}>}KEY)

13 Replies
Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

If it is a Qlik Sense question, post it in the Qlik Sense area, not in Qlik Datamarket .

I moved the topic, so this time you can forget about the comment.

May you live in interesting times!
Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

Try this:

Count({<KEY = {"=Len(Trim([c-i-hh_gender])) = 0"}>}KEY)

Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

Just exclude Null values in dimension properties.

Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

Hi Hanan,

Try this: if(count(KEY)=0,'',count(Key))

G.

Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

Hi Ralf,

That works only in Sense, when you have values without connected dimension.

Man | Woman | -

10    |  10         | 5

You can with that filter out the -, 5 column.

G.

Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

How else you can have nulls in a pie chart?

Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

Hi Ralf,

Short example:

Man | Woman | Other

10    |  10        |    -

A table (fact):

ID     S     Value

1     Man      5

2     Woman 6

3     Man      5

4     Woman 4

B table (dimension):

Man

Woman

Other

G.

Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

Thanks All and Sunny

Not applicable

## Re: Qliksense Pie Chart: Excluding Null values

But the (right) expression Sum(Value) will never gets you NULL.

Community Browser