Thanks everyone,
This is just what I needed.

Appreciate the help.


Thanks

…….Cameron

From: IBM Mainframe Discussion List <IBM-MAIN@LISTSERV.UA.EDU> On Behalf Of 
Lars Höglund
Sent: Monday, January 29, 2024 11:10 AM
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Sv: How can I determine the User Name associated with the current 
Batch JOB RACF ID?

Something like this Code Extract: LINKAGE SECTION. 01 CB1. 05 PTR1 POINTER 
OCCURS 512. 01 CVT. 05 CVT1 POINTER OCCURS 512. 01 CB2. 05 PTR2 POINTER OCCURS 
256. . . . SET ADDRESS OF CB2 TO PTR1(4) MOVE CB2(1: 8) TO WS-BJOBNAMN SET 
ADDRESS OF CB2


Something like this



Code Extract:



LINKAGE SECTION.



01 CB1.

  05 PTR1 POINTER OCCURS 512.

01 CVT.

  05 CVT1 POINTER OCCURS 512.

01 CB2.

  05 PTR2 POINTER OCCURS 256.

.

.

.

SET ADDRESS OF CB2          TO PTR1(4)

MOVE CB2(1:8)                    TO WS-BJOBNAMN

SET ADDRESS OF CB2          TO PTR1(46)

MOVE CB2(361:8)              TO WS-BPGM

SET ADDRESS OF CB2          TO PTR2(80)

MOVE CB2(13:8)                 TO  BJOBNR

SET ADDRESS OF CB1          TO NULL

SET ADDRESS OF CB1          TO PTR1(138)

SET ADDRESS OF CB2          TO PTR1(28)

MOVE CB2(193:8)             TO WS-BUSER







-----Ursprungligt meddelande-----

Från: IBM Mainframe Discussion List 
<IBM-MAIN@LISTSERV.UA.EDU<mailto:IBM-MAIN@LISTSERV.UA.EDU>> För Cameron Conacher

Skickat: den 29 januari 2024 14:37

Till: IBM-MAIN@LISTSERV.UA.EDU<mailto:IBM-MAIN@LISTSERV.UA.EDU>

Ämne: How can I determine the User Name associated with the current Batch JOB 
RACF ID?



[Du f?r inte e-post ofta fr?n 
000003cfc59146bb-dmarc-requ...@listserv.ua.edu<mailto:000003cfc59146bb-dmarc-requ...@listserv.ua.edu>.
 L?s om varf?r det h?r ?r viktigt p? 
https://aka.ms/LearnAboutSenderIdentification<https://isolate.menlosecurity.com/1/3735928037/https:/aka.ms/LearnAboutSenderIdentification>
 ]



Good Morning,

I know I can do this in CICS, but I am digging around to see if this can be 
done in a batch COBOL program.

Basically, I just want to include Fred's Name in a report I generate, where 
Fred is the RACF ID associate with the currently executing Batch JOB. (a COBOL 
program).

I could write something to call out to CICS (EXCI maybe) to get a name.

But I wanted to know if there is anyway to do this by calling some routines 
from my Batch COBOL program.



I am assuming right now, it is not possible since I have come up empty so far.



Thanks





Cameron Conacher

Senior Engineer



American Express Canada Inc.

GCICS

2225 Sheppard Avenue East, Toronto, ON  M2J 5C2



cameron.conac...@aexp.com<mailto:cameron.conac...@aexp.com><mailto:cameron.conac...@aexp.com<mailto:cameron.conac...@aexp.com>>

Office: 1-437-836-5265

Mobile: 1-416-409-5147



https://amex.webex.com/join/cameron.conacher







________________________________

American Express made the following annotations 
________________________________ This e-mail was sent to you by a 
representative of Amex Bank of Canada, P.O. Box 3204, Station "F", Toronto, ON, 
M1W 3W7, 
www.americanexpress.ca<https://isolate.menlosecurity.com/1/3735928037/http:/www.americanexpress.ca>.
 If you no longer wish to receive these e-mails, please notify the sender by 
reply e-mail.



This e-mail is solely for the intended recipient and may contain confidential 
or privileged information. If you are not the intended recipient, any 
disclosure, copying, use, or distribution of the information included in this 
e-mail is prohibited. If you have received this e-mail in error, please notify 
the sender by reply e-mail and immediately and permanently delete this e-mail 
and any attachments. Thank you.



American Express a fait les remarques suivantes Ce courriel vous a ?t? envoy? 
par un repr?sentant de la Banque Amex du Canada, C.P. 3204, succursale F, 
Toronto (Ontario) M1W 3W7, 
www.americanexpress.ca<https://isolate.menlosecurity.com/1/3735928037/http:/www.americanexpress.ca>.
 Si, par la suite, vous ne souhaitez plus recevoir ces courriels, veuillez en 
aviser les exp?diteurs par courriel.



Ce courriel est r?serv? au seul destinataire indiqu? et peut renfermer des 
renseignements confidentiels et privil?gi?s. Si vous n'?tes pas le destinataire 
pr?vu, toute divulgation, duplication, utilisation ou distribution du courriel 
est interdite. Si vous avez re?u ce courriel par erreur, veuillez en aviser 
l'exp?diteur par courriel et d?truire imm?diatement le courriel et toute pi?ce 
jointe. Merci.



----------------------------------------------------------------------

For IBM-MAIN subscribe / signoff / archive access instructions, send email to 
lists...@listserv.ua.edu<mailto:lists...@listserv.ua.edu> with the message: 
INFO IBM-MAIN



----------------------------------------------------------------------

For IBM-MAIN subscribe / signoff / archive access instructions,

send email to lists...@listserv.ua.edu<mailto:lists...@listserv.ua.edu> with 
the message: INFO IBM-MAIN

________________________________
American Express made the following annotations
________________________________
This e-mail was sent to you by a representative of Amex Bank of Canada, P.O. 
Box 3204, Station "F", Toronto, ON, M1W 3W7, www.americanexpress.ca. If you no 
longer wish to receive these e-mails, please notify the sender by reply e-mail.

This e-mail is solely for the intended recipient and may contain confidential 
or privileged information. If you are not the intended recipient, any 
disclosure, copying, use, or distribution of the information included in this 
e-mail is prohibited. If you have received this e-mail in error, please notify 
the sender by reply e-mail and immediately and permanently delete this e-mail 
and any attachments. Thank you.

American Express a fait les remarques suivantes
Ce courriel vous a été envoyé par un représentant de la Banque Amex du Canada, 
C.P. 3204, succursale F, Toronto (Ontario) M1W 3W7, www.americanexpress.ca. Si, 
par la suite, vous ne souhaitez plus recevoir ces courriels, veuillez en aviser 
les expéditeurs par courriel.

Ce courriel est réservé au seul destinataire indiqué et peut renfermer des 
renseignements confidentiels et privilégiés. Si vous n’êtes pas le destinataire 
prévu, toute divulgation, duplication, utilisation ou distribution du courriel 
est interdite. Si vous avez reçu ce courriel par erreur, veuillez en aviser 
l’expéditeur par courriel et détruire immédiatement le courriel et toute pièce 
jointe. Merci.

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to