Testing the Subroutine

How to:

After compiling and storing a subroutine, you can test it in a report request. In order to access the subroutine, you need to issue the ALLOCATE command for z/OS.

If an error occurs during testing, check to see if the error is in the request or in the subroutine.

Procedure: How to Determine the Location of Error

You can determine the location of an error with the following:

  1. Write a dummy subroutine that has the same arguments but returns a constant.
  2. Execute the request with the dummy subroutine.

If the request executes the dummy subroutine normally, the error is in your subroutine. If the request still generates an error, the error is in the request.