Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

kunkumnaveen
Contributor III

working fine with straight table but not with kpi's charts

Hello All,

What making me confuse is i am using same dimension  and same expression in two diff charts (kpis,straight table),but i am getting two diff results

i mean ..my default when end user open dashboard he as to see all the location aduit score ...which is working fine in both table chart and kpi chart ....

if he goes feather and select only particular location from the drop down then he should only see that selected location with score ...

which is working great in table but its not working in kpis charts,

what i looking is when i select  location, only selected KPI chart  has to show the value the rest kpi chart  needle should be at zero....

straight table:

dimension:LOCATION

expressionSmiley Frustratedum({<ADATE={"$(=max(ADATE))"}>}OVERALL_SCR)(working fine)

kpi chartSmiley Sadchanderia kpi chart)


dimension:LOCATION

expressionSmiley Frustratedum({<LOCATION={'CHANDERIA'},ADATE={"$(=max(ADATE))"}>}OVERALL_SCR)

Help me in resloving this task,

Please find the attachment(data screen short)

thanks

naveen

1 Solution

Accepted Solutions

Re: working fine with straight table but not with kpi's charts

Found the problem. You need to remove the LOCATION from dimension. Check out the attached

30 Replies

Re: working fine with straight table but not with kpi's charts

Can you try this may be for Chanderia location and do the same for the other locations as well.

=GetFieldSelections(LOCATION) = 'CHANDERIA', Sum({<LOCATION = {'CHANDERIA'}, ADATE ={"$(=Max(ADATE))"}>} OVERALL_SCR), 0)

kunkumnaveen
Contributor III

Re: working fine with straight table but not with kpi's charts

Hello sunny,

i think something is missing in the expression syntax do we need to use any if statment,because the result i am getting is

                            NO DATA DISPLAY

I JUST COPY PASTE UR EXPRESSION

=GetFieldSelections(LOCATION) = 'CHANDERIA',Sum({<LOCATION = {'CHANDERIA'}, ADATE ={"$(=Max(ADATE))"}>} OVERALL_SCR), 0)

THANKS

NAVEEN

Re: working fine with straight table but not with kpi's charts

Oh sorry, forgot to add if

=If(GetFieldSelections(LOCATION) = 'CHANDERIA', Sum({<LOCATION = {'CHANDERIA'}, ADATE ={"$(=Max(ADATE))"}>} OVERALL_SCR), 0)

kunkumnaveen
Contributor III

Re: working fine with straight table but not with kpi's charts

Hello Sunny ,

one  problem is solved, but this solution bring me a new problem what i mean is

step1:

my default without selection, the end user has to see all the three locations score  ,chanderia,deberia,zawar


step2:

if he select any particular location from drop down then the selected kip chart needle has to show the score,

the rest two kpi's chart needle should be zero


by writhing your expression i am achieving step2:

but by  default i  need step 1:


may be in the expression the getfieldselection might not need


thanks

naveen





Re: working fine with straight table but not with kpi's charts

Try this:

=If(SubStringCount(Concat(DISTINT LOCATION, ', '), 'CHANDERIA') = 1, Sum({<LOCATION = {'CHANDERIA'}, ADATE ={"$(=Max(ADATE))"}>} OVERALL_SCR), 0)

kunkumnaveen
Contributor III

Re: working fine with straight table but not with kpi's charts

Hello Sunny,

The expression working fine with CHANDERIA location ,but its not working on two other location even though i replace

location name like this

=If(SubStringCount(Concat(DISTINCT LOCATION, ', '), 'DEBARI') = 1, Sum({<LOCATION = {'DEBARI'}, ADATE ={"$(=Max(ADATE))"}>} OVERALL_SCR), 0)

=If(SubStringCount(Concat(DISTINCT LOCATION, ', '), 'ZAWAR') = 1, Sum({<LOCATION = {'ZAWAR'}, ADATE ={"$(=Max(ADATE))"}>} OVERALL_SCR), 0)

i was very happy that i achieved this requirement,when chanderia kpi chart was working ,

thanks

naveen

Re: working fine with straight table but not with kpi's charts

For the first expression, is it DEBARI or DARIBA? From the screenshot it seems that it might be DARIBA unless this is a different location?

kunkumnaveen
Contributor III

Re: working fine with straight table but not with kpi's charts

HELLO,

DEBARI

PLEASE FIND THE ATTACHMENT (DATA SLIDE )

Re: working fine with straight table but not with kpi's charts

If you put this in a text box object -> =SubStringCount(Concat(DISTINCT LOCATION, ', '), 'DEBARI') do you see 1 when DEBARI location is selected? Similarly try this -> =SubStringCount(Concat(DISTINCT LOCATION, ', '), 'ZAWAR') to gives you 1 when ZAWAR is selected.

I want to make sure the if statement is the issue or the expression itself is the issue

Community Browser