My IPeople

Community discussion for IPeople products and services
Welcome to My IPeople Sign in | Help
in
Home Blogs Forums

Debugging the cause of the ERROR LOC for String Length or Symbol Table Overflow (MAGIC)

Last post 11-21-2007, 8:48 AM by Brian. 0 replies.
Sort Posts: Previous Next
  •  11-21-2007, 8:48 AM 591

    Debugging the cause of the ERROR LOC for String Length or Symbol Table Overflow (MAGIC)

    Sometimes an NPR Report crashes and a screen pops up with some information about the crashed report.  One piece of data that appears is the ERROR LOC.  There is a specific number that links to each type of error that causes a crash.  For instance, there is a specific number for a Symbol Table Overflow.  There is another number for exceeding the acceptable String Length (255 characters).  These numbers are unique to each Meditech network.

    A Symbol is a variable that stores a value.  As NPR Report Writers create more and more complex reports, they often use these Symbols, sometiems referred to as Variables.  These Symbols are recorded in a Symbol Table.  The space allocated for each Symbol Table is 1 block, or 1KB (1024 bytes).  A byte is required to display a character.  If the characters in your Symbols and their values exceed 1024, you experience Symbol Table Overflow which causes your report to crash.  (Users most often get around this by changing all of their variables to "global" or "slash" variables.  MAGIC Programmers can also get around this by appending X to the end of their program call, forcing a "stacking" of the symbol tables).

    Meditech's Operating System allows a maximum length of 255 characters for any string.  If you exceed that legnth, your report crashes.

    To determine what the ERROR LOC number is for each of these types of errors, you can create an NPR Report and cause it to crash on purpose by replicating the error type. 

    For instance, here are some quick steps to force a Symbol Table Overflow error:

    - Create an NPR Report for any DPM, enter a Report Title and an Active Y flag, then enter this Footnote: AL START ""^X,DO{X+1^X^X[X]}

    Here are the steps to force a String Length error:

    - Create an NPR Report for any DPM, enter a Report Title and an Active Y flag, then enter this Footnote: AL START ""^X,DO{X+1^X_X^X}

    When your reports run, they will crash.  You can then make note of the ERROR LOC number.  You can then make note of that number and refer to it whenever you have another report that crashes.  If you spot that number, you now know if the report crashed because of either Symbol Table Overflow or String Length.

View as RSS news feed in XML
Powered by Community Server, by Telligent Systems