Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

iluilyas
New Contributor III

Using Set Analysis to filter table data

Dear All

Point-1:

I have a straight table to show the details of Active employees.

I have used this expression in "EMPLY_ID" field  "=if(EmpActive=1,EMPLY_ID)" and unchecked "Show null values" which is working exactly as the way i wanted.

I would like to know if i can use Set Analysis for this purpose?

The reason being, i would like to filter also by another condition.

Point-2:

I am also facing another issue. I have put a filter "EmpType" which has three distinct values D, F & L. I'm showing the EmpType as one of the column in this table. But when i select "F" type in filter, my table is not showing only F type employees. It still shows all records.

Is this due to the condition i put in EMPLY_ID field?


Regards

Ilyas

1 Solution

Accepted Solutions

Re: Using Set Analysis to filter table data

Try this.

Count({<EmpActive = {1}>}EmployeeID)


This should solve both of your problem.


Regards,

Kaushik Solanki

13 Replies

Re: Using Set Analysis to filter table data

Try this.

Count({<EmpActive = {1}>}EmployeeID)


This should solve both of your problem.


Regards,

Kaushik Solanki

MVP
MVP

Re: Using Set Analysis to filter table data

Are you using the above as an expression or calculated dimension?

iluilyas
New Contributor III

Re: Using Set Analysis to filter table data

Hi Kaushik

Where to use this? I m using this in expression.

if(EmpActive=1,EMPLY_ID)


I also tried below and it worked. However, i would like to use Set Analysis

if(EmpActive=1 and upper(NATION_TYPE)='NATIONAL',EMPLY_ID)

iluilyas
New Contributor III

Re: Using Set Analysis to filter table data

Im using in expression Sunny. Calculated dimension is bit confusing to me

Re: Using Set Analysis to filter table data

You Should use it in expression.

Keep Emply_ID as Dimension and

Count({<EmpActive = {1}>}Emply_ID)


As Expression


Regards,

Kaushik Solanki

iluilyas
New Contributor III

Re: Using Set Analysis to filter table data

I'm getting "Invalid Dimension" error

MVP
MVP

Re: Using Set Analysis to filter table data

From your response to Kaushik above, it seems you are using calculated dimension. You need to use his expression as an expression, and not a dimension.

If you share a sample, one of us might be able to show you what exactly you need to do here

iluilyas
New Contributor III

Re: Using Set Analysis to filter table data

Im using desktop. I have attached the screenshots. let me know if this is ok?

Re: Using Set Analysis to filter table data

Hi,

You should select Measure from the "Add Column" option and then put the expression.

Regards,

Kaushik Solanki