Checking the Syntax Remotely (COBOL)

As well as editing files on the mainframe, you can use Enterprise Developer for z Systems to compile applications directly on the mainframe.
Before you begin, ensure the ZBNKPRT1 program is still open, remove the ) on the WS-FIRST-REC data item on line 008100, and then save the code. This saves the changes on the mainframe.
Since a new change was made, another background parse is performed and errors noted in the margin. As you hover the mouse over the red markers, the syntax error for that line is displayed.

Even though the errors in the source are clearly displayed from the background parse, you should perform a syntax check of the COBOL program with the Enterprise COBOL dialect set, on the mainframe. You can use the Workflow Manager to model remote compilation for languages other than COBOL too.

  1. In Application Explorer view, right-click the ZBNKPRT1 member and choose Remote Syntax Check.

    GUID-231BDF0C-755C-41A3-9A87-052B0EB99C1C-low.png

    A dialog box appears, prompting you for additional compiler directives. This allows you to specify additional directives for the mainframe compiler, and the CICS and DB2 preprocessors.

    GUID-AEE4C174-F384-4A6F-92B0-5791C6EA0197-low.png

  2. Click OK.

    The code is compiled on the mainframe, using the mainframe compiler. If any syntax errors are detected, they are displayed in the Error Feedback view, shown below:

    GUID-2A16494E-726C-45E3-898C-8A1C29D0DFF6-low.jpg

  3. To go directly to the error you created within the source file, double-click the syntax error with ID IGYDS1168. You are prompted to associate the error with the source member.

    GUID-8647C585-227D-4637-92EB-263959315CB5-low.png

  4. Click Yes. The syntax error is shown in the editor, along with the error code. This allows you to locate and fix errors quickly.
  5. Correct the error, save, then repeat step 1. The code now compiles cleanly.