Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us in Toronto Sept 9th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
deepakqlikview_123
Specialist
Specialist

not able to drill down into chart after selection of data by using mouse in a chart

I am using below conditional expression  for chart but when i am trying to select data in a chart by using mouse it is not ablr to drill trough the data

it seems if else giving problem

for one if statement it works properly but when applying below expression not working properly

below is the expression

=if(Country='Mexico',if(DATE>='03/31/2005',Date(MONTHYEAR,'MMM-YY')),

   if(WildMatch(Country,'China'),if(YEAR>=2011,Date(MONTHYEAR,'MMM-YY')),

   if(WildMatch(Country,'Brazil'),Date(MONTHYEAR,'MMM-YY'),

   YEAR&':'&QUARTER)))

plz suggest

1 Solution

Accepted Solutions
settu_periasamy
Master III
Master III

Hi deepak,

There is no problem for displaying the values in calculated dimension. But when we trying the select the dimension value (like YEAR &":"&QUARTER), it will override the other selection and it doesn't meet your criteria in the calculated dimension field. (you can check this if you convert line chart to straight table).

Still, you can achieve this using the Enable Conditional display like you already applied in the Conditional Expression.

=if(Country='Mexico',if(DATE>='03/31/2005',Date(MONTHYEAR,'MMM-YY')),

  if(WildMatch(Country,'China'),if(YEAR>=2011,Date(MONTHYEAR,'MMM-YY')),

  if(WildMatch(Country,'Brazil'),Date(MONTHYEAR,'MMM-YY'),

  YEAR&':'&QUARTER)))

For Dimension1

    =Date(MONTHYEAR,'MMM-YY')

put the enable condition like

    WildMatch(Country,'Mexico','China','Brazil')


For Dimension 2 (Already you have the field YrQr, if you are using YEAR &':"&QUARTER, we can't re select in the value in the Chart)

=replace(YrQr,'-',':')

Enable Condition

WildMatch(Country,'Mexico','China','Brazil')=0


Regarding the DATE>'03/31/2005 for 'Mexico'  -> you can give in the expression like

=(Avg({<INDICATOR_NAME={'Mexico - Real Home Price Index'},DATE={'>=03/31/2005'}>}INDICATOR_VALUE))

Expression for 'China'

=(Avg({<INDICATOR_NAME={'China - Real Home Price Index'},YEAR={'>=2011'}>}INDICATOR_VALUE))

PFA for your reference (due to your file size, i removed all data, you can just copy the Chart, paste into your file)

Hope this helps.

View solution in original post

4 Replies
settu_periasamy
Master III
Master III

Hi,

you can check this

=if(Country='Mexico',

  if(DATE>='03/31/2005',Date(MONTHYEAR,'MMM-YY'),

    if(WildMatch(Country,'China'),if(YEAR>=2011,Date(MONTHYEAR,'MMM-YY'),

   if(WildMatch(Country,'Brazil'),Date(MONTHYEAR,'MMM-YY'),

   YEAR&':'&QUARTER)))))

deepakqlikview_123
Specialist
Specialist
Author

Hi Settu,

It is not working properly.

I have attached my sample file for this , whenever i am trying to select by using mouse it is not able to show the selections i have used conditional enabling for expressions and calculated dimension.

thanks

settu_periasamy
Master III
Master III

Hi deepak,

There is no problem for displaying the values in calculated dimension. But when we trying the select the dimension value (like YEAR &":"&QUARTER), it will override the other selection and it doesn't meet your criteria in the calculated dimension field. (you can check this if you convert line chart to straight table).

Still, you can achieve this using the Enable Conditional display like you already applied in the Conditional Expression.

=if(Country='Mexico',if(DATE>='03/31/2005',Date(MONTHYEAR,'MMM-YY')),

  if(WildMatch(Country,'China'),if(YEAR>=2011,Date(MONTHYEAR,'MMM-YY')),

  if(WildMatch(Country,'Brazil'),Date(MONTHYEAR,'MMM-YY'),

  YEAR&':'&QUARTER)))

For Dimension1

    =Date(MONTHYEAR,'MMM-YY')

put the enable condition like

    WildMatch(Country,'Mexico','China','Brazil')


For Dimension 2 (Already you have the field YrQr, if you are using YEAR &':"&QUARTER, we can't re select in the value in the Chart)

=replace(YrQr,'-',':')

Enable Condition

WildMatch(Country,'Mexico','China','Brazil')=0


Regarding the DATE>'03/31/2005 for 'Mexico'  -> you can give in the expression like

=(Avg({<INDICATOR_NAME={'Mexico - Real Home Price Index'},DATE={'>=03/31/2005'}>}INDICATOR_VALUE))

Expression for 'China'

=(Avg({<INDICATOR_NAME={'China - Real Home Price Index'},YEAR={'>=2011'}>}INDICATOR_VALUE))

PFA for your reference (due to your file size, i removed all data, you can just copy the Chart, paste into your file)

Hope this helps.

deepakqlikview_123
Specialist
Specialist
Author

Thanks Settu