Skip to main content
Announcements
Customer Spotlight: Discover what’s possible with embedded analytics Oct. 16 at 10:00 AM ET: REGISTER NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
pover
Luminary Alumni
Luminary Alumni

Chart with conditional expressions slow

Hello everyone,

I have a interesting problem with a chart that has conditional expressions to show and hide the chart expressions.  My chart is like the personalized report in "What's new in QV 11?", but in the my application I have 80 possible expressions.  The funny thing is that if I select to show expressions that are the first ones in the list of expressions in the property window, the chart calculates instantly.  If I select to show expression that are the last ones in the list of expressions in the property window, the chart calculates slowly.  If I move those same expressions from the end of the list to the start of the list of expressions, the chart calculate instantly.  So my question is, why would the position of the expression matter how fast the chart calculates?  Doesn't QlikView have to go though the whole expression list regardless?

Anybody else see anything similar?

Karl

10 Replies
Not applicable

Hi Karl,

I was just wondering if you ever made any headway on this issue? Facing something similar, so would be great to hear your findings.

Thanks,

Graeme

m_woolf
Master II
Master II

Can you share the expression for showing the chart?

Not applicable

Do you mean the expression for showing the expression conditionally (there is no conditional show expression for this particular chart)? 

An example would be:

=$(V.FN.AdHocFieldSelected([%UI.PnlBreakdown.AdHocExpression], 'Total Day Change'))

Where V.FN.AdHocFieldSelected is defined as:

SubStringCount('|'& Concat(DISTINCT {AdHoc} $1,'|')&'|', '|'& $2 &'|' )>0

I saw a bug in the release notes for SR7 about the concat function and "|", so I tried another delimiter too.  I am just seeing generally poor performance as the number of expressions grows.  The degradation of the performance seems disproportionate, as most of the expressions are disabled most of the time.  I'm still at the early stages of investigation, but this post was the first one that came up in my search results, hence the question. 

pover
Luminary Alumni
Luminary Alumni
Author

Hi Graeme,

I talked to QlikTech support at the time and they did agree that is was a bug.  I stopped working for that customer, so I never confirmed if the problem was fixed in a later release.  I was using conditional show expressions, but I never isolated the problem enough to know if the problem was the expression itself or the conditional show feature.  It doesn't sound too crazy to think that if the problem was the conditional show feature, the same problem may exist with the disable expression feature.

Karl

Not applicable

Hi Karl,

Thanks for the information.  I think I'll try and get SR7 rolled out and see if that helps (It resolves a few other bugs I raised, so won't be wasted time for us).  The application I'm seeing the issue in is very complex, so it may well just be a case of "death by a thousand cuts", as I'm having difficulty isolating any specific culprit for the performance hit.

Thanks for taking the time to reply.

cheers,

Graeme

john_duffy
Partner - Creator III
Partner - Creator III

Hello Graeme and Karl.

Where you able to find any further information on this issue?

I am using QV11 SR2 and am experiencing the same slow performance when using conditional expressions.

In my case, I only have 21 expressions.  The conditional expression is very simple - Show Variable = 1.

Thanks,

John.

Not applicable

Hi John,

I think the problem may be with the performance of the SubStringCount function - looks like it may be a bug, or some sort of performance issue.  When I removed it, the performance improved dramatically.  See this post for more details.

Re: GetSelectedCount and Alternative State

Regards,

Graeme

john_duffy
Partner - Creator III
Partner - Creator III

Hi Graeme.

Thanks for the response and info.

In my case, I am not using the SubStringCount function or Concat function.

My expressions are fairly simple (aggr,sum, etc.) and my conditional expression is simply a variable set to 0 or 1.

Like Karl expierienced, when the first set of expressions are displayed, the performance is great.  As soon as I start to show expressions further along in the chart, the performance slows down.  With all expressions displayed, the performance is very slow.  If I remove the conditional expressions and therefore show all expressions, the performance is great.

Thanks,

John.

Not applicable

Hi John,

Thanks for the information.  There may well be a few issues at play here.  In my particular scenario, the SubStringCount was definitely a major contributor, but there may be other issues too (like the one you described).  Removing the substringcount however has gotten us back to an acceptable level of performance for now.  Useful to hear your observations too, and would be great if you can post back any findings / resolution.

Thanks,

Graeme