IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Get jobname using EZACFSM1


IBM Mainframe Forums -> All Other Mainframe Topics
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
rajatbagga

Active User


Joined: 11 Mar 2007
Posts: 199
Location: india

PostPosted: Thu Jul 10, 2008 12:58 pm
Reply with quote

Can anybody tell me how we can write the JOB name into a PS file using EZACFSM1.

Regards,
Rajat
Back to top
View user's profile Send private message
Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Thu Jul 10, 2008 6:55 pm
Reply with quote

Do you want the name of the job executing EZACFSM1 or the job about to be submitted by the EZACFSM1 step?
Back to top
View user's profile Send private message
rajatbagga

Active User


Joined: 11 Mar 2007
Posts: 199
Location: india

PostPosted: Sat Jul 12, 2008 10:21 pm
Reply with quote

hello,

I want the job about to be submitted by the EZACFSM1 step to be written in a PS file.

Regrads,
Rajat
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Sat Jul 12, 2008 10:38 pm
Reply with quote

Hello,

I'm confused. . . icon_confused.gif

You mention you want the name and then later you want the job.

Please post what you "have" and what you want to be put into the PS file.

What are you hoping to get in this topic that you did not get in your earlier topic about EZACFSM1?
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Sat Jul 12, 2008 11:22 pm
Reply with quote

EZACFSM1 will get the jobname of the currently executing job...

how do You expect for EZACFSM1 to find the name of the job being submitted?
the jobname is part of the input, so there should be no need to get it from anywhere
unless there was a language misunderstanding !
Back to top
View user's profile Send private message
rajatbagga

Active User


Joined: 11 Mar 2007
Posts: 199
Location: india

PostPosted: Tue Jul 15, 2008 4:02 pm
Reply with quote

hello,

Yes I want the jobname of the currently executing job to be written in a PS file using EZACFSM1 ...

Regards
Rajat
Back to top
View user's profile Send private message
Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Wed Jul 16, 2008 2:13 am
Reply with quote

JOB1 is executing EZACFSM1 to submit JOB2.

Do you want "JOB1" to be written into a file?

Do you really want to submit JOB2 or are you only trying to get the name of the currently executing job? There are REXX and COBOL samples out here to do that. EZACFSM1 doesn't do that.
Back to top
View user's profile Send private message
rajatbagga

Active User


Joined: 11 Mar 2007
Posts: 199
Location: india

PostPosted: Thu Jul 17, 2008 8:24 am
Reply with quote

hello,

Yes, i want JOB1 to be written into PS file. But I thought EZACFSM1 can also do this. But anyways let me know how a COBOL pgm can do this.

Regards,
Rajat.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Thu Jul 17, 2008 2:28 pm
Reply with quote

IIRC it should be possible
try this
Code:

//SYMBOLS EXEC PGM=EZACFSM1       
//SYSOUT    DD  SYSOUT=*           
//SYSIN     DD  *                 
DAY        '&DAY'                 
HHMMSS     '&HHMMSS'               
HR         '&HR'                   
JDAY       '&JDAY'                 
JOBNAME    '&JOBNAME'             
LDAY       '&LDAY'                 
LHHMMSS    '&LHHMMSS'             
LHR        '&LHR'                 
LJDAY      '&LJDAY'               
LMIN       '&LMIN'                 
LMON       '&LMON'                 
LSEC       '&LSEC'                 
LWDAY      '&LWDAY'               
LYR2       '&LYR2'                 
LYR4       '&LYR4'                 
LYYMMDD    '&LYYMMDD'             
MIN        '&MIN'                 
MON        '&MON'                 
SEC        '&SEC'                 
SEQ        '&SEQ'                 
SID        '&SID'                 
SYSCLONE   '&SYSCLONE'             
SYSNAME    '&SYSNAME'             
SYSPLEX    '&SYSPLEX'             
SYSR1      '&SYSR1'               
SYSUID     '&SYSUID'               
WDAY       '&WDAY'                 
YR2        '&YR2'                 
YR4        '&YR4'                 
YYMMDD     '&YYMMDD'               
CCYY/MM/DD '&YR4./&LMON./&LDAY'   
HH:MM:SS   '&HR.:&MIN.:&SEC'       


to find the systems symbols try
http://home.flash.net/~mzelden/mvsutil.html
and look for IPLINFO.TXT
Back to top
View user's profile Send private message
Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Fri Jul 18, 2008 3:17 am
Reply with quote

Follow erico's example with '&JOBNAME' but direct SYSOUT to a dataset.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Fri Jul 18, 2008 1:05 pm
Reply with quote

Hi,

Use of EZACFSM1 was some what new for me, after Enrico's reply did a little search on this, got to learn enough new. Found a link describing the symbols used, might be usable for someone else as well -

publibz.boulder.ibm.com/cgi-bin/bookmgr_OS390/BOOKS/IEA1E241/2.2.2
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Fri Jul 18, 2008 3:38 pm
Reply with quote

Hi,

I tried the JOB to do what is being discussed in this thread -
Code:
//SYMBOLS EXEC PGM=EZACFSM1                               
//SYSOUT    DD  DSN=HLQ.JOBNAE.IN.PS,DISP=(,CATLG)     
//SYSIN     DD  *                                         
JOBNAME    '&JOBNAME'                                     
/*                                                         


Now the Data Set "HLQ.JOBNAE.IN.PS" is present under ISRDDN, how & why ? Please suggest.
Back to top
View user's profile Send private message
enrico-sorichetti

Superior Member


Joined: 14 Mar 2007
Posts: 10873
Location: italy

PostPosted: Fri Jul 18, 2008 3:44 pm
Reply with quote

Quote:
Now the Data Set "HLQ.JOBNAE.IN.PS" is present under ISRDDN, how & why ? Please suggest.


sometimes a dataset is left around after a browse ( just checked )
strange enough but happens for PS datasets, not for PDS
Back to top
View user's profile Send private message
Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Fri Jul 18, 2008 7:14 pm
Reply with quote

If you used ISPF 3.2 to create the file it probably stays allocated as enrico said. You can use TSO command FREE FILE(ddname) to unallocate it.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Mon Jul 21, 2008 11:01 am
Reply with quote

Hi Bill,
Bill Dennis wrote:
If you used ISPF 3.2 to create the file it probably stays allocated as enrico said.
No, I didn't allocate it using 3.2, instead it was created in the JOB due to the below statement of the JOB posted in previous post of mine,
Code:
//SYSOUT    DD  DSN=HLQ.JOBNAE.IN.PS,DISP=(,CATLG)


Quote:
You can use TSO command FREE FILE(ddname) to unallocate it.
ok thanks, but it was there on Friday ( July 18,2008 IST) , when I logged in to mainframes today (Monday, July 21,2008 IST) it's not there, what should I conclude..? Please assist.
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Mon Jul 21, 2008 11:42 am
Reply with quote

Hi Anuj,

Quote:
when I logged in to mainframes today (Monday, July 21,2008 IST) it's not there
Does this mean the dataset is no longer on the system or that it no longer appears in isrddn?

Quote:
what should I conclude..?
If it no longer appears in isrddn, you did something last week to cause this dataset to be found by isrddn and have not done so this morning.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Mon Jul 21, 2008 12:04 pm
Reply with quote

Hi Dick,
dick scherrer wrote:
Does this mean the dataset is no longer on the system or that it no longer appears in isrddn?
It means it doen't appear in ISRDDN.

Quote:
If it no longer appears in isrddn, you did something last week to cause this dataset to be found by isrddn and have not done so this morning.
That day I submit the JOB & browse the DSN to check the output, that's it from my side.
Back to top
View user's profile Send private message
Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Mon Jul 21, 2008 6:50 pm
Reply with quote

Since you didn't code a UNIT, possibly it was created in a "work" dasd pool that is cleaned up on a regular schedule? Perhaps someone else deleted it? Check with the storage mgmt group at your site.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Thu Aug 14, 2008 4:09 pm
Reply with quote

Hi,

Once again, one more query about EZACFSM1-

To get the value of SYSUID I used the below JOB ..
Code:
//SYMBOLS EXEC PGM=EZACFSM1 
//SYSOUT    DD  SYSOUT=*     
//SYSIN     DD  *           
JOBNAME    '&JOBNAME'       
SYSUID     '&SYSUID'         
/*                           
//*                         

..but the out put was

Code:
JOBNAME    'Anuj'
SYSUID     '&SYSUID' 

..for SYSUID I was expecting my RACF ID to appear in output..?

Please assist, what's the reason behind..or is it this way only..
Back to top
View user's profile Send private message
Bill Dennis

Active Member


Joined: 17 Aug 2007
Posts: 562
Location: Iowa, USA

PostPosted: Thu Aug 14, 2008 6:47 pm
Reply with quote

&SYSUID will be resolved in any normal JCL submit. You don't need EZACFSM1 for that.
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Thu Aug 14, 2008 6:51 pm
Reply with quote

Agreed, I just tried the example posted by Enrico earlier in this thread & this concern was raised. However, if just for an experiment if I would like to do this, is there a way..?
Back to top
View user's profile Send private message
Anuj Dhawan

Superior Member


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

PostPosted: Thu Aug 14, 2008 6:53 pm
Reply with quote

Bill Dennis wrote:
.. be resolved in any normal JCL submit.
BTW, I'm not aware about abnormal JCL concept yet.. icon_smile.gif
Back to top
View user's profile Send private message
superk

Global Moderator


Joined: 26 Apr 2004
Posts: 4652
Location: Raleigh, NC, USA

PostPosted: Thu Aug 14, 2008 7:00 pm
Reply with quote

I think the answer is that &SYSUID is not a dynamic system symbol or a static system symbol.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> All Other Mainframe Topics

 


Similar Topics
Topic Forum Replies
No new posts Using the Jobname parameter in a Qual... ABENDS & Debugging 1
No new posts To replace jobname in a file with ano... SYNCSORT 12
No new posts Assambly code to get the jobname ? PL/I & Assembler 16
No new posts Regarding 'TSO OUTPUT jobname(jobid)' TSO/ISPF 17
No new posts EZACFSM1 created file name - passing ... JCL & VSAM 23
Search our Forums:

Back to Top