18 Regenerate Source Code

This chapter contains these topics:

When regenerating source code you should know:

  • When to regenerate source code

  • How to solve a generation error

18.1 When to Regenerate Source Code

You should regenerate a program whenever you modify a program specification. You should regenerate your programs when you:

  • Change the program type

  • Add or remove a file from the program file specifications

  • Change the content of a file

    You must repeat the File Specifications step in this situation to enter the new information into the Detailed Programming Facility.

  • Add or change a function exit or selection exit

  • Change a data field definition parameter, for example:

    • Add, change, or delete a PDL

  • Add, change, or delete the Full Data Field Parameters

  • Add Processing Options to a program that previously did not have any, or delete all Processing Options

  • Change the Lockout Action field values

When you add, change, or remove a file in the program or change the program type, you must access the File Specifications screen from the Define Generator Specification screen and click Enter to submit the Detailed Field Specifications interactive job.

You can view all changes on the SEU by entering 30 in the Option field on the Software Versions Repository.

Columns 1 and 2 include a 21 for lines you add, 22 for changes, and 23 for lines you delete.

18.2 Changing CAP Status

If you change the CAP Status field, the system deletes the changes in the Source Entry Utility that it stores in the P member of the Additional Help/Modifications Master file (F93002). JD Edwards World recommends that you do not change the CAP Status field unless the changes you make to your program become unmanageable. When the CAP Status field is set to Y, you can regenerate your program from one JD Edwards World release to the next.

Change the CAP Status to N when either of the following occurs:

  • You test the program and are ready to move it into production.

  • You must make large manual changes that the program generator cannot generate for you. For example, adding special subroutines or complicated calculation logic.

To change CAP status

  1. On Define Generator Specification, enter 1 in the following field next to Program Purpose and Type.

    • Option

  2. On Program Purpose and Type, enter N in the following field.

    • CAP Status

    Figure 18-1 Program Purpose and Type screen

    Description of Figure 18-1 follows
    Description of "Figure 18-1 Program Purpose and Type screen"

    The Delete KBG Modifications screen displays.

    Figure 18-2 Delete KGB Modifications screen

    Description of Figure 18-2 follows
    Description of "Figure 18-2 Delete KGB Modifications screen"

  3. To remove the modifications member, choose Delete (F6).

    The Define Generator Specification screen displays.

18.3 Resolving CAP Status Invalid Error

The Program Generator verifies that the job completes normally before each source generation. When the program generator does not complete normally or if you delete the specifications for a program, the system sends an error message to your workstation that states:CAP Status Invalid for program Pxxxx ... generation terminated.

If you receive a message in the job log indicating that the buffer length is longer than the record, or field AGSRCS is not found, verify that the JDESRC file in your source library exists and has a length of 142 and 8 fields.

To resolve the CAP Status Invalid error, perform any of the following:

Possible Resolution Description
Ensure the CAP status is set to Y on the Program Purpose and Type screen. Any job that prevents the MPxxxxx job from completing normally will change the CAP Status to N.
  • Allow the MPxxxxx job to complete.

  • Do not cancel it in the job queue.

If you change the CAP Status field to N, the system deletes the changes in the Source Entry Utility that it stores in the P member of the Additional Help/Modifications Master file (F93002).

If the File Specifications ends abnormally, the system changes the value in the CAP Status field to D. Change the value in the CAP Status field to Y and process the file specifications.

Ensure the Pxxxxx member exists in the Additional Help/Modifications Master file (F93002). The Pxxxxx member must exist in order to generate a program.

The system initially creates the Pxxxxx member during the Program Purpose and Type definition step.

Ensure the Mxxxxx member does not exist in F93002. The Mxxxxx member must not exist in order to generate a program.

Use the RMVM command to remove this member.

Ensure that one step of the generation process completes before you start the batch job of another step. NA