For Enterprise Cobol try WHEN-COMPILED intrisic function.

https://www.ibm.com/docs/en/cobol-zos/6.5.0?topic=functions-when-compiled

El dom, 28 dic 2025, 9:42, Farley, Peter <
[email protected]> escribió:

> Both the Enterprise COBOL and PL/I compilers have the compile-time option
> SERVICE to store an identifying string in the generated program.  In our
> shop the SCLM process generates an identifying string for each compile run
> telling when and from where (project ID) and by whom (TSO ID) the program
> was last translated.
>
> However, unless I missed it there is no documented way to extract that
> string at runtime (e.g., to log the version that is executing).
>
> Aside from control-block chasing within the generated code (PPA1/2/3/4,
> etc.), does anyone know if there is a function available to do that?
>
> I have looked over the LE Vendor Interfaces guide, but that only seems to
> show in which control block the SERVICE string can be found and does not
> document a function to retrieve the string.
>
> TIA for any help you can provide.
>
> Peter
>
> This message and any attachments are intended only for the use of the
> addressee and may contain information that is privileged and confidential.
> If the reader of the message is not the intended recipient or an authorized
> representative of the intended recipient, you are hereby notified that any
> dissemination of this communication is strictly prohibited. If you have
> received this communication in error, please notify us immediately by
> e-mail and delete the message and any attachments from your system.
>
> ----------------------------------------------------------------------
> For IBM-MAIN subscribe / signoff / archive access instructions,
> send email to [email protected] with the message: INFO IBM-MAIN
>

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to [email protected] with the message: INFO IBM-MAIN

Reply via email to