ibmi-brunch-learn

Announcement

Collapse
No announcement yet.

How to check the stmtheap on V5R4?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to check the stmtheap on V5R4?

    How can I check the statement heap size(stmtheap) on a V5R4 machine?

    We are getting an error message "SQL0101N: The statement is too long or too complex" and I am trying to find out the current size of the statement heap, but I can't find it.

  • #2
    Re: How to check the stmtheap on V5R4?

    Check the reason code on 2nd lvl SQL0101 message.
    Philippe

    Comment


    • #3
      Re: How to check the stmtheap on V5R4?

      The reason code is:

      Error Code :-101
      SQLState :54001

      Comment


      • #4
        Re: How to check the stmtheap on V5R4?

        I have had this error before. Seems like a generic "huh?" from the compiler.

        On one table, I get this every time I try to add a field with ALTER. This table has dozens of views using it, I think the compile just can handle so many.

        On another case, I had a view that worked just fine, but every so often it errored. Found the cause was statements like Select min(itmdesc) ... and we had a number of records where itmdesc was null. Seems it handled it ok until the number of records in error reached a critical point, then failed.

        Just a couple of maybe's if you don't get the exact error.

        Comment


        • #5
          Re: How to check the stmtheap on V5R4?

          The reason code can NOT be -101. Put the cursor on the SQL0101 message line, hit <F1> and drill down into the HELP text to check the reason code.
          BTW where are you getting this message from ?
          Last edited by Mercury; December 13, 2007, 10:02 AM.
          Philippe

          Comment

          Working...
          X