7 Replies Latest reply: Aug 5, 2014 8:35 AM by Patrick Gendron RSS

    Variable Length Limit?

      Hi Everyone,

       

      Is there a limit to the Length of a given variable in QlikView 8.5?

       

      Long story short, I'm using QlikView 8.5 for a client to create a simluated P&L statement.

       

      I'm using a Pick-Match setup, and populating the MATCH part with 40+ different choices.  To make the code reusable, instead of this:

       

      PICK(MATCH([Metric ID], 1, 2, 3...39, 40), SUM(1), MAX(2), AVG(3)...SUM(39), SUM(40))

       

      I'm doing this:

       

      PICK(MATCH([Metric ID], $(MetricIDList)), $(MetricSyntaxList))

       

      The problem is, my $(MetricSyntaxList) variable is now 5,200+ characters, and no longer works.  I know my syntax is correct, because it works if it's under 5,200 characters and breaks if it's over 5,200 characters.

       

      Any thoughts?

       

      Thanks in advance.

        • Variable Length Limit?
          John Witherspoon

          I don't think there is supposed to be a limit.  That said, I believe I've run into expression length limits before when specifically trying to test that.  When long enough, I've had valid expressions crash out the entire application.

           

          Unfortunately, I don't know of a good workaround for what you seem to be trying to do. 

           

          Maybe if you need this in a chart type that allows hidden expressions, you could check for a limited number of metrics in several different pick(match()) expressions.  Then create a final expression that picks the first non-null value from the previous results.  That's assuming the limit is related to one expression or variable, and not to the total across several.  Since the limit is likely a bug, it's very hard to guess what might and might not work.

          • Variable Length Limit?

            Hi Corey, I had the same problem in a big customer with big complex expression in version 8.5, unfortunately we could not find a good way the solve it, but to migrate to version 9. I guess you can have a good chance using hidden expressions as John pointed out.

             

            Regards

            • Variable Length Limit?
              Valeriy Shylin

              Guys,

               

              we are having the same problem with Qlikview 10 SR3.

               

              We have some very long formulas in a dozen of variables. One table incorporates all the calculations, so the table expression has a number of IFs that decide which variable to display.

               

              At a certain point the table stops evaluating the variables.

               

              We consider this a bug since there are no explicit indications by Qliktech about the variable length limit.

               

              Regards,

              Valeriy Shylin