When running BC1JAAPI to list element data, how do you run more than one query ?

book

Article ID: 41004

calendar_today

Updated On:

Products

CA Endevor Software Change Manager (SCM) CA Endevor Software Change Manager - Natural Integration (SCM) CA Endevor Software Change Manager - ECLIPSE Plugin (SCM) CA Endevor Software Change Manager - Enterprise Workbench (SCM)

Issue/Introduction

Issue:

The client wants to run multiple queries using the API program ENTBJAPI under job hlq.iprfx.CSIQIJCL(BC1JAAPI). How is this done ?

Resolution:

You can use the same message and output file ddnames with DISP=MOD :

//MSG3FILE DD  DSN=&&MSG3FILE,DISP=(MOD,PASS),    
//             UNIT=SYSDA,SPACE=(TRK,(5,5)),      
//             DCB=(RECFM=FB,LRECL=133,BLKSIZE=0) 
//EXT1ELM  DD  DSN=&&EXT1ELM,DISP=(MOD,PASS),     
//             UNIT=SYSDA,SPACE=(TRK,(5,5)),      
//             DCB=(RECFM=VB,LRECL=2048,BLKSIZE=0)

 

Multiple query statements in the input :

//SYSIN *
* EXTRACT AN ELEMENT WITH NO FORMAT - CURRENT VERSION & LEVEL 
AACTL MSG3FILEEXT1ELM                                         
AEELMHE  ENV1    1SYSTEMA SUBSYSA  APITEST   COBOL             
RUN                                                           
AEELMHE  ENV1    1SYSTEMA SUBSYSA  BSTTRD06  COBOL             
RUN                                                           
* LAST CALL, ENSURE THAT THE API SERVER IS SHUTDOWN.          
AACTLY                                                        
RUN                                                           
QUIT         
/*                                               

Alternately, you can use multiple message and output file ddnames.

 

Environment

Release:
Component: ENDBAS