Welcome to the SRP Forum! Please refer to the SRP Forum FAQ post if you have any questions regarding how the forum works.

SRP Editor Hits MFS

We have a table that is actually split across 10 different tables. It has an mfs, and when I try to open a record in the table, it hits the debugger. One of the variables passed into the mfs isn’t in the correct format. How do I find out what is passing these parameters to the MFS ? And I don’t have a problem writing or reading from the table using programming statements. And I don't have a problem when I use System editor++.

John Win.

User: John Win

Comments

  • John,

    What do you see in the Call Stack from with the Debugger? Can you post the content of the variable when you have a problem and then can you post the content of the variable when you do not have a problem? That will help us to point you in the right direction.

    Off hand, however, I do not know why there would be a problem with the SRP Editor. OpenInsight calls your MFS for you. We never pass anything directly into the MFS itself. I believe we just use standard Read or Xlate statements.
  • The Call Stack is

    DA_USAGE_MFS
    RTP16
    SRP_EDITOR_OPEN_RECORD_EVENTS
    REPOS.STPROCEXE..EXECUTE
    REPOSITORY
    EXECNPHANDLER
    $$$SYSPROG*..OIWIN*
    RUN_EVENT
    REQUEST_INFO
    UTLILITY
    DIALOG_BOX
    SRP_EDITOR_EVENTS

    Subroutine DA_USAGE_MFS ( Code, BFS, Handle, Name, FMC , Record, Status )

    The variable that caused the problem is "Name" The value is '%RECORDS%'. When it works, the value of variable is numeric. The Runtime Error message is "Non-numeric data when numeric required. Zero used"

    I understand the message, I just don't know how I go about determining why %RECORDS% is passed in.

    User: John Win
  • John,

    The SRP Editor attempts to read the %RECORDS% record first before it selects all of the keys in the table. This is only done when you attempt to use the Open Record feature. If you have %RECORDS% in the data table then this implies you have a QuickDex (or RightDex) on the table and the full list of keys is already available. Thus, it makes sense to use the %RECORDS% content if it is available. So this explains that mystery.

    I suggest that you update your MFS logic to be tolerant of non-numerical keys.
Sign In or Register to comment.