Defining Debug Settings in PLIDEBUG.DAT

Note: Using PLIDEBUG.DAT is currently only supported on Windows platforms.

CodeWatch lets you specify debug initialization settings for individual programs in the control file called PLIDEBUG.DAT. This file is utilized by the PL/I run-time system whenever a program is initialized under Enterprise Server. It is automatically created if it doesn't exist in the location pointed to by the PL/I Configuration directory setting in the Enterprise Server Administration PL/I tab. You can edit this file from Enterprise Developer to define the program name and how to start and initialize CodeWatch.

When using PLIDEBUG.DAT, there should be only one record for each program you wish to debug under Enterprise Server.
Important: The control record is column sensitive so be careful when constructing a record for your program. A corresponding layout file (PLIDEBUG.STR) is available in the PL/I Enterprise Server demos for assistance with column/data alignment.
Example:
 --- 0---|--- 10---|--- 20---|--- 30---|--- 40---|--- 50---|--- 60---|--- 70---|--- 80---|--- 90---|
123456789|123456789|123456789|123456789|123456789|123456789|123456789|123456789|123456789|123456789|
TESTPGM1            N 0 SHLIB TESTPGM1.DLL;ENV TESTPGM;BR %ENTRY;BR %EXIT [DET;Q];C 
Important: The starting column is assumed to be 0 as this is the default. It can be changed to 1 from the Data Tools Options.

This table outlines the values needed for each record in PLIDEBUG.DAT.

Column(s) Value Description
0 through 7 <program name> User program name (without file extension). For example: TESTPGM1
20 Y/N (Yes/No) Indicates whether to start the debugger when the program executes. Set to N to skip attaching the debugger.
22 0/1 The debugger flavor used to debug the entry. Values are:
  • 0 = Use the CodeWatch command line debugger.
  • 1 = Use the CodeWatch GUI debugger
24-nn <text string> Initial set of debugger commands to be issued by CodeWatch during start-up before control is given over to the user.

For example:

TESTPGM1            N 0 SHLIB TESTPGM1.DLL;ENV TESTPGM;BR %ENTRY;BR %EXIT [DET;Q];C 
                       
TESTPGM2            N 1 SHLIB TESTPGM2.DLL;ENV TESTPGM;BR %ENTRY;BR %EXIT [DET;Q];C 

Editing PLIDEBUG.DAT

To open the and edit the debug configuration file:

  1. After running your JCL job to create the PLIDEBUG.DAT file, right-click the file in the Solution Explorer and choose Open File in Data Tools. The Micro Focus Data Tools application starts.
    Note: A message box may appear indicating that edits to the file are applied immediately. Select the Do not show this message again check box to prevent this message from appearing. Then click OK.
  2. Right-click in the record editor for PLIDEBUG.DAT and choose Insert Indexed Record. The Insert indexed record dialog box appears.
  3. Enter the value for the User program name without the file extension. This is the Unique key for the record. Click OK. A line appears showing the Unique key appears in the record editor.
  4. On the line with the new record, click on column 20 and enter Y or N to indicate whether to start the debugger when the program executes.
    Note: Make sure that the first Y is in column 20. The current line and column numbers are shown in the information bar at the bottom of the window. Note that the starting column is assumed to be 0 as this is the default. It can be changed to 1 from the Data Tools Options. If your starting point is 1, make sure that the first Y is in column 21.
  5. Click on column 22 and enter 0 or 1 to specify which debugger to use.
  6. Click on column 24 and enter the remaining values for the initialization text string. See the section CodeWatch Commands for detailed information on commands you can use in the initialization text string.
    Note:

    The Data Tools status bar shows the cursor's current column location. Changes are saved immediately to the file.

    When you begin to enter the remaining values for the record, a message box asks you to confirm that you want to edit the record. Click OK. You can also turn the update warning off for the file in the message box.