Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Sokkorn
Honored Contributor

How can I filter data base on Expression?

Hi All,

I want to create button to filter data by colore. In the attached file, I have create 3 button that need to to filter data base on expression. How can I do this?

Thanks in advanced!

Regards,

Sokkorn Cheav

1 Solution

Accepted Solutions

Re: How can I filter data base on Expression?

Hi,

If you want to see the variables you need to press Ctrl + Alt + V and set different values for color like 1,2,3 of variable vOne and change the colors of the chart.

See the attached sample.

Regards

Anand

10 Replies

Re: How can I filter data base on Expression?

Hi,

You need to create a inline table and put this three condition for the colors and use this fields to filter out the data. For Green, Yellow, Red and use this fields to filter the conditions.

Regards,

Annad

Re: How can I filter data base on Expression?

Hi,

Or you do one thing also dont need to create a button to filter the data of the Green, Yellow, Red i suggest you to create a Resident table and load the table with your Green, Yellow, Red condition like this

Load

*,

IF([Call Setup]>='95.00%','Green',

IF([Call Setup]<'95.00%' and [Call Setup]>='74.00%' ,'Yellow',

IF([Call Setup]<'74.00%','Red'))) as FilterField

Resident TableName;

Regards,

Anand

Re: How can I filter data base on Expression?

Hi,

See the attached sample file might be it is your solution i thing.

Lets see i create this sample because i am not able to load your QVW file.

Regards

Anand

Sokkorn
Honored Contributor

Re: How can I filter data base on Expression?

Hi Anand,

Thanks for your reply. Your anwser is help me so much, but it still not fit with my requirement. I try with your solution.

Regards,

Sokkorn

Re: How can I filter data base on Expression?

Hi,

There is anothere solution for you also lets try this and let me know. I create one variable named vOne and by selecting the button it display the Green, Red,  Yellow data but it display only see the attached sample file let me know whether it works for you or not.

I put this condition on your condition add variables and by selectiob the button it will change.

IF([Call Setup]>='95.00%' and vOne=1,Green(),

IF([Call Setup]<'95.00%' and [Call Setup]>='74.00%' and vOne=2 ,Yellow(),

IF([Call Setup]<'74.00%'and vOne=3,LightRed())))

Click on button one by one and check it, see Solution Sheet.

Regards

Anand

Sokkorn
Honored Contributor

How can I filter data base on Expression?

HI Anand,

I cannot find the variable vOne in the attached. Can you do it agin for me.

Many thanks for your help.

Regards,

Sokkorn

Re: How can I filter data base on Expression?

Hi,

If you want to see the variables you need to press Ctrl + Alt + V and set different values for color like 1,2,3 of variable vOne and change the colors of the chart.

See the attached sample.

Regards

Anand

Sokkorn
Honored Contributor

Re: How can I filter data base on Expression?

Hi Anand,

This one is help me so much. One more can I hide or exclude from chart where the value don't have color?

Regards,

Sokkorn

Re: How can I filter data base on Expression?

Hi,

I thing for that you need to create a resident table for that and create a another column as which mantains this colors in resident table like in this code

Load

*,

IF([Call Setup]>='95.00%','Green',

IF([Call Setup]<'95.00%' and [Call Setup]>='74.00%' ,'Yellow',

IF([Call Setup]<'74.00%','Red'))) as FilterField

Resident YourTableName;

Regards,

Anand

Community Browser