> For the complete documentation index, see [llms.txt](https://docs.editran.onesait.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.editran.onesait.com/documentacion-editran/ibm-editran-v5.3-ims-en/utilidades-ims/eleccion-de-nucleo-en-procedimientos-onesait-editran.md).

# Core selection in Onesait Editran procedures

To avoid duplication of procedures when there is more than one send/receive database and, therefore, different Editran cores, a new step must be added to the procedures as a preliminary step to the existing ones; this will create the ZTBGF032 file, necessary for the execution of the procedures, with the appropriate record for the corresponding core according to the session for which it is run.

The step to add will be the one corresponding to JCL ZTBGJNUC, which is supplied in the product installation, appropriately adapted, and which is shown below:

```cobol
//KI1056EA JOB (EGDC,KIT,,99),TRAN-NUCLEO,MSGCLASS=H,CLASS=A,          
//             MSGLEVEL=1,NOTIFY=&SYSUID                               
//PASOTRN  EXEC PGM=ZTBGBNUC,                                          
//         PARM='E000099930000099940PRUEBAPRUEBA/CBLQDA(ON)'           
//STEPLIB  DD DSN=KI.EGDI.LOAD,DISP=SHR                                
//         DD DSN=IMSP.SDFSRESL,DISP=SHR                            
//ZTBGFNUC DD DSN=KI.EGDI.ZTBG.ZTBGFNUC,DISP=SHR                       
//ZTBGF032 DD DSN=KI.EGDI.PRUE.ZTBGF032,DISP=(NEW,CATLG,DELETE),       
//            DCB=(RECFM=FB,LRECL=80,BLKSIZE=80),                      
//            SPACE=(TRK,(500,50),RLSE)                                
//SYSOUT   DD SYSOUT=*                                                 
//                                                                      
```

The ZTBGFNUC file is a fixed-blocked 80-byte PS file that contains the BMP records (which are currently in ZTBGF032) corresponding to the different databases, and after each one, the associated core. It also contains the execution record of the step that lists the issued files (ZTBGLFE) in the post-issue procedure.

The ZTBGFNUC file is supplied as an example in the product installation and is as follows:

```cobol
********************************* Top of Data **********************************
BMP,PROGRAM,ZTGBGENUC,,,N00000,,,,,,,,IMST,,                                   
BMP,PROGRAM,ZTBGEIG1,,,N00000,,,,,,,,IMST,,                                ZTB1
BMP,PROGRAM,ZTBGEIG2,,,N00000,,,,,,,,IMST,,                                ZTB2
BMP,PROGRAM,ZTBGEIG3,,,N00000,,,,,,,,IMST,,                                ZTB3
BMP,PROGRAM,ZTBGEIG4,,,N00000,,,,,,,,IMST,,                                ZTB4
BMP,PROGRAM,ZTBGEIG5,,,N00000,,,,,,,,IMST,,                                ZTB5
BMP,PROGRAM,ZTBGELFE,,,N00000,,,,,,,,IMSP,,                                ZLFE
******************************** Bottom of Data ********************************
```

In the procedures, the output file ZTBGF032 will be defined as temporary (OLD,PASS,DELETE) and in the steps where it is currently used, DISP=SHR must be changed to DISP=(OLD,PASS,DEL).

## Example.

Post-issue procedure:

```cobol
//             PROC ORIGIN=,FUNCTION=,L0=,                              
//             L1=,L2=,R1=,R2=,PR=,AP=                                 
//*--------------------------------------------------------------------
//* INDRA                                                             *
//*--------------------------------------------------------------------
//*   POST-ISSUE PROCEDURE OF EDITRAN/G                                 *
//*--------------------------------------------------------------------
//*  DATA:                                                            *
//*      ORIGIN (O=OPERATOR,E=EDITRAN,A=APPLICATION JCL) ----> 1 BYTE  *
//*                                                                   *
//*      FUNCTION (02=PROCESS POST-ISSUE PRESENTATION                  *
//*               05=END OF PRESENTATION ISSUE)         -----> 2 BYTES *
//*                                                                   *
//*      PRESENTATION SESSION:                                        *
//*        LOCAL CODE L1  --------------------------------> 6 BYTES *
//*                     L2  --------------------------------> 3 BYTES *
//*        REMOTE       R1  --------------------------------> 6 BYTES *
//*                     R2  --------------------------------> 3 BYTES *
//*        APPLICATION  PR  --------------------------------> 6 BYTES *
//*                                                                   *
//*      TRANSMISSION SESSION (EDITRAN/P):                         *
//*        APPLICATION  AP  --------------------------------> 6 BYTES *
//*                                                  TOTAL = 33 BYTES *
//*      LOCAL ENVIRONMENT ALIAS (FOR SPECIAL USES)                  *
//*                     L0  --------------------------------> 3 BYTES *
//*--------------------------------------------------------------------
//PASOTRN  EXEC PGM=ZTBGBNUC,                                          
//         PARM='&ORIGIN&L1&L2&R1&R2&PR&AP/CBLQDA(ON)'                 
//STEPLIB  DD DSN=KI.EGDI.LOAD,DISP=SHR                                
//         DD DSN=IMS910P.SDFSRESL,DISP=SHR                            
//ZTBGFNUC DD DSN=KI.EGDI.ZTBG.ZTBGFNUC,DISP=SHR                       
//ZTBGF032 DD DSN=&&ZTGF032,DISP=(NEW,PASS,DELETE),                    
//            DCB=(RECFM=FB,LRECL=80,BLKSIZE=80),                      
//            SPACE=(TRK,(500,50),RLSE)                                
//SYSOUT   DD SYSOUT=*                                                 
//                                                                     
//*--------------------------------------------------------------------
//A3P EXEC PGM=ZTBGB130,REGION=4M,                                     
//             PARM='&ORIGIN&FUNCTION&L1&L2&R1&R2&PR&AP/CBLQDA(ON)'     
//STEPLIB  DD DSN=IMS910P.SDFSRESL,DISP=SHR                            
//         DD DSN=KI.EGDI.LOAD,DISP=SHR                                
//         DD DSN=KI.GCDA.SCDES.LOAD,DISP=SHR                          
//DFSVSAMP DD DSN=IMS910P.PROCLIB(DFSVSAMP),DISP=SHR                   
//ZTBGFLOG DD SYSOUT=*                                                 
//ZTBGF032 DD DSN=&&ZTGF032,DISP=(,PASS,DEL)                           
//ZTBGFLIS DD SYSOUT=*                                                 
//ZTBGFMSJ DD SYSOUT=*                                                 
//ZTBGFPRI DD SYSOUT=*,DCB=(BLKSIZE=105)                               
//ZTBGFINT DD   SYSOUT=(H,INTRDR),DCB=(BLKSIZE=80)                     
//FICHKDES DD DSN=KI.GCDA.CIFRIMS.FICHKDES,DISP=SHR                    
//CEEDUMP  DD SYSOUT=*                                                 
//SYSOUT   DD SYSOUT=*                                                 
//SYSTCPD  DD DSN=SW.TCPIP.SEZAPARM(TCPDATB2),DISP=SHR                 
//      SET LOCAL0=&L0                                                 
//*                                                                    
//*--------------------------------------------------------------------
//* STEP TO OUTPUT LIST OF ISSUED FILES                        *
//*--------------------------------------------------------------------
//*   FUNCTION -------------------------------------------> 2 BYTES    *
//*       00 - OUTPUTS THE LIST REGARDLESS OF THE PRESENTATION STATUS*
//*       02 - OUTPUTS THE LIST IF THE PRESENTATION STATUS IS FINALIZED. *
//*   PRES. SESSION OR TRANS. SESSION (DEPENDING ON ORIGIN)> 24 BYTES   *
//*--------------------------------------------------------------------
//ZTBGLFE EXEC PGM=ZTBGBLFE,REGION=4M,COND=(0,NE,A3P),                 
//             PARM='&ORIGIN&FUNCTION&L1&L2&R1&R2&PR&AP/CBLQDA(ON)'     
//STEPLIB  DD DSN=IMS910P.SDFSRESL,DISP=SHR                            
//         DD DSN=KI.EGDI.LOAD,DISP=SHR                                
//ZTBGFLOG DD SYSOUT=*                                                 
//ZTBGF032 DD DSN=&&ZTGF032,DISP=(,PASS,DEL)                           
//* THIS FILE IS NECESSARY IF THE VSAM STATUS MANAGER IS USED  
//ZTBGFLFE DD SYSOUT=*                                                 
//ZTBGFPRI DD SYSOUT=*,DCB=(BLKSIZE=105)                               
//SYSOUT   DD SYSOUT=*                                                 
//CEEDUMP  DD SYSOUT=*                                                 
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.editran.onesait.com/documentacion-editran/ibm-editran-v5.3-ims-en/utilidades-ims/eleccion-de-nucleo-en-procedimientos-onesait-editran.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
