How do I link from a DC COBOL program to an ADS dialog? Using TRANSFER CONTROL RETURN abends with a 3020 error code.

book

Article ID: 15645

calendar_today

Updated On:

Products

CA IDMS CA IDMS - Database CA IDMS - ADS

Issue/Introduction



I have COBOL program linking to an ADS dialog with the following code:

TRANSFER CONTROL 'DIALOG1' RETURN .       

The program DIALOG1 is ADS mainline dialog. I am getting error:

DC027007 TASK ABENDED WITH CODE 3020

A 3020 error code means the request cannot be serviced because of an I/O, program-not-found, or potential deadlock error.

How do I link from a COBOL program to an ADS dialog?

 

Environment

Release: IDADSO00100-18.5-ADS-for CA-IDMS
Component:

Resolution

ADS dialog load modules can only be executed under the control of the ADS runtime system so it is not possible to link to ADS dialogs directly. 

A COBOL program can instead execute the following command to invoke a dialog:

DC RETURN NEXT TASK CODE 'DIALOG1' . 

The task code needs to be defined with the same name as the dialog name and invoke program ADSOURN1. 

ADD TASK DIALOG1
       INVOKES PROGRAM ADSORUN1
       NOINPUT .                   



 

Additional Information

Also see TEC593343 for another way to do it with SQL procedures.