Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

How to capture the userid of the user who submits the job

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
reachsudheer

New User


Joined: 23 Apr 2007
Posts: 2
Location: chennai

PostPosted: Thu Aug 14, 2008 1:07 pm    Post subject: How to capture the userid of the user who submits the job
Reply with quote

Hi,

I need to capture the mainframe userid of the user who submits the cobol program to display in the report.

JOB A
PGM B
USER user1
USER user1

JOB A executes the PGM B and if USER user1 submits the job,
prgoram PGMB should capture user1 and write in my report in the program dynamically, if USER use2 submits then user2 should be written in my report .

Thanks & Regards
Sudheer
Back to top
View user's profile Send private message

expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Thu Aug 14, 2008 1:16 pm    Post subject:
Reply with quote

Why reinvent the wheel ?

The system should already have this information stored in the SMF type30 records. Make sure that these are captured with the systems programmers, and the data is already available without you having to capture what has already been captured.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6966
Location: porcelain throne

PostPosted: Thu Aug 14, 2008 1:27 pm    Post subject:
Reply with quote

wouldn't accessing the SMF type 30 record be an 'after the job ran' type of thing? I don't know, just asking.

this kind of silliness could be also accomplished by the proper construction of jcl to provide(generate with a set? )a parm to the step, that would be dependent upon the userid symbolic. or can not the <userid> symbolic that one can put in the notify= job card (I don't mean the actual userid, I mean the symbolic that resolves to the userid.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Thu Aug 14, 2008 1:39 pm    Post subject:
Reply with quote

Yes, &SYSUID would do it.

But I guess it depends on what the info is required for. If it is for perf & capacity, billing, or what - the information remains the same where ever the source is.

As for after the event, I really can't see what the difference is, the report will still be the same...................... won't it ?
Back to top
View user's profile Send private message
Escapa

Senior Member


Joined: 16 Feb 2007
Posts: 1399
Location: IL, USA

PostPosted: Thu Aug 14, 2008 2:32 pm    Post subject:
Reply with quote

PARM=&SYSUID

works well
Back to top
View user's profile Send private message
reachsudheer

New User


Joined: 23 Apr 2007
Posts: 2
Location: chennai

PostPosted: Thu Aug 14, 2008 2:45 pm    Post subject: Reply to: How to capture the userid of the user who submits
Reply with quote

This job will be submitted many users so when ever any user submits the job it will generate a report.

Idea is that if we can capture the Userid from cobol we can write the userid in the report.

regards
Sudheer
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8593
Location: Back in jolly old England

PostPosted: Thu Aug 14, 2008 2:58 pm    Post subject:
Reply with quote

OK, the obvious question is why are these statistics wanted.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Thu Aug 14, 2008 3:55 pm    Post subject: Re: How to capture the userid of the user who submits the jo
Reply with quote

Hi,
reachsudheer wrote:
.. who submits the cobol program to display in the report.
Probably you wanted to say, some JCL/JOB was SUBmitted..

Quote:
JOB A executes the PGM B and if USER user1 submits the job,
prgoram PGMB should capture user1 and write in my report in the program dynamically, if USER use2 submits then user2 should be written in my report .
It's quite a strange requirement, again, once 'captured', how "all this" would be used..? Can "EZACFSM1" be your choice..
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts IMS region inactive - User abend code... gthmrj IMS DB/DC 5 Tue Mar 07, 2017 12:29 pm
No new posts User Cancels the job PANDU1 DB2 1 Sat Mar 04, 2017 8:21 pm
No new posts How to Capture the Max return code of... anilkumar922 All Other Mainframe Topics 2 Thu Jan 12, 2017 12:02 pm
No new posts SORT - E15 and E35 using same user ex... Abhi Nature DFSORT/ICETOOL 12 Mon Oct 03, 2016 4:33 pm
No new posts User exit in COBOL programs ganasrinivasan PL/I & Assembler 0 Thu Aug 18, 2016 12:48 pm


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us