> 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-comun-z-os/interfaces-de-programas-de-aplicacion/incorporacion-de-mensajes-en-el-log-de-presentaciones-de-onesait-editran/ejemplo.md).

# Ejemplo

Los campos que aparecen en la copy del ZTBGB006 a los que no se hace referencia en el apartado anterior no pueden utilizarse.

```cobol
WORKING-STORAGE SECTION.
*-----------------------

01  ÁREA-ZTBGB006                   PIC X(200) VALUE LOW-VALUES.
*-                                                             -*
 01  FILLER REDEFINES ÁREA-ZTBGB006.                             
     05  ORIGEN-ZTBGB006               PIC X.                    
     05  CODIGO-RDO-ZTBGB006           PIC 9(4).                 
     05  SENTIDO-ZTBGB006              PIC X(01).                
     05  GRABAR-SISLOG-ZTBGB006        PIC X(01).                
     05  SESION-PRESENTACION-ZTBGB006  PIC X(24).                
     05  SESION-TRANSMISION-ZTBGB006.                            
         07  LOCAL-TRANSMISION-ZTBGB006   PIC X(9).              
         07  REMOTO-TRANSMISION-ZTBGB006  PIC X(9).              
         07  APLICA-TRANSMISION-ZTBGB006  PIC X(6).              
     05  CODIGO-MENSAJE-ZTBGB006       PIC 9(4).                 
     05  PROGRAMA-INC-ZTBGB006         PIC X(8).                 
     05  FILLER REDEFINES PROGRAMA-INC-ZTBGB006.                 
         10 IDENT-MENSAJE-ZTBGB006     PIC X(3).                 
         10 FILLER                     PIC X(5).                 
     05  RECURSO-INC-ZTBGB006          PIC X(8).                 
     05  RETORNO-INC-ZTBGB006.                                   
         10  F-S-INC-ZTBGB006          PIC X(2).                 
         10  RESTO-INC-ZTBGB006        PIC X(3).                 
     05  FILLER REDEFINES RETORNO-INC-ZTBGB006.                  
         10  ERRCOD-INC-ZTBGB006       PIC 9(5).                 
     05 TEXTO-ULT-MSJE-ZTBGB006        PIC X(60).                
     05 XRESP-ZTBGB006.                                          
        10 RESP-ZTBGB006               PIC 9(05).                
     05 XRAZON-ZTBGB006.                                         
        10 RAZON-ZTBGB006              PIC 9(05).                
     05 FILLER                         PIC X(50).                
*-                                                             -*
01  ÁREA-ZTBGB110.
           05  LONGITUD-ZTBGB110        PIC 9(4) COMP.
           05  ORIGEN-ZTBGB110          PIC X.
           05  FUNCION-ZTBGB110         PIC XX.
           05  SESION-PRESENTACION-ZTBGB110.
               10  LOCAL-ZTBGB110       PIC X(9).
               10  REMOTO-ZTBGB110      PIC X(9).
10	APLICACION-ZTBGB110  PIC X(6).
           05  FICHCAR-ZTBGB110         PIC X.
•	-*
LINKAGE SECTION.
*----------------
*
 01  ÁREA-PASO PIC X(29).
*
 PROCEDURE DIVISION USING ÁREA-PASO.
*-----------------------------------
 N1-P-PROGRAMA.
*
      MOVE LOW-VALUES       TO ÁREA-ZTBGB006
      MOVE ‘U’              TO ORIGEN-ZTBGB006
      MOVE ZEROS            TO CODIGO-RDO-ZTBGB006
      MOVE 'E'              TO SENTIDO-ZTBGB006
      MOVE 'S'              TO GRABAR-SISLOG-ZTBGB006
      MOVE SESION-PRESENTACION-ZTBGB110
                            TO SESION-PRESENTACION-ZTBGB006
      MOVE LOW-VALUES       TO SESION-TRANSMISION-ZTBGB006
      MOVE 1331             TO CODIGO-MENSAJE-ZTBGB006
      MOVE 'USU'            TO IDENT-MENSAJE-ZTBGB006
      MOVE 'ESTO ES UNA PRUEBA DE MENSAJE DE USUARIO'
                            TO TEXTO-ULT-MSJE-ZTBGB006
 *
       CALL ZTBGB006  USING ÁREA-ZTBGB006.
      IF CODIGO-RDO-ZTBGB006 NOT = ZEROS
         DISPLAY 'ERROR EN ZTBGB006, RDO = ' CODIGO-RDO-ZTBGB006.

```

En la consulta del LOG en Editran/G aparece:

```
05/05/20 15:47:24           CONSULTA FICHERO LOG            EDITRAN/G V-5.1  
TIPO  CODIGO      SESION PRESENTACION      APL.TRANS.    FECHA       HORA    
E U   USU1331  000099940 000099990 PRUJCB              05/05/2000  15:37:13  
ESTO ES UNA PRUEBA DE MENSAJE DE USUARIO                                     
                                                                              
```


---

# 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-comun-z-os/interfaces-de-programas-de-aplicacion/incorporacion-de-mensajes-en-el-log-de-presentaciones-de-onesait-editran/ejemplo.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.
