IMFEXEC MV GETDATAN


BMC Software recommends accessing the array with the IMFEXEC MV GETDATAN command as an alternative to the IMFEXEC MV GETDATA command.

Use the IMFEXEC MV GETDATAN command in a REXX EXEC because storage-related problems might occur when the command is used from a CLIST.

Some advantages of using the IMFEXEC MV GETDATAN command over IMFEXEC MV GETDATA are that the GETDATAN command

  • is easier to use
  • requires less coding
  • simplifies access to MainView data
Warning

Note

Note that the IMFEXEC MV GETDATA and IMFEXEC MV GETDATAN commands cannot be used together on the same channel. If you attempt to use both commands on the same channel, you will receive a return code of 28.

When you use the IMFEXEC MV GETDATAN command to retrieve data from a channel the CHANNEL(channelname) keyword is always required. The data returned from the specified channel is parsed into REXX STEM variables that are built by using a fixed format name. Refer to Stem-variables-returned-by-IMFEXEC-MV-GETDATAN for more information.

You must also specify the REFRESH keyword the first time you request data from a specific channel with GETDATAN. By default, a maximum of 500 rows of data are returned. To override the default value, specify the COUNT(nnnnn) keyword where nnnnn can be a number from 1 to 99999.

When EXEC returns the specified number of lines (or the default 500) and additional unreturned data remains, you receive a return code of 4. In this situation, you should schedule additional IMFEXEC MV GETDATAN calls, without specifying the REFRESH keyword, to retrieve additional lines of data. Continue to schedule additional calls until you receive a return code of 0, which indicates that no more lines of data are left.

After you have gathered your data and no longer have a use for the channel, it is a good practice to release all resources with the IMFEXEC MV RELEASE command (see MV-RELEASE). If your EXEC immediately terminates when it is finished with the data and channel, you can skip the release step because EXEC termination cleanup releases the resources for you. The IMFEXEC MV RELEASE will clean up and free the channel resources and it will free all the storage associated with the stem variables that are housing the MainView data.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*

MainView AutoOPERATOR 8.1