How to rewrite PDS directory stats in REXX or ISPF



TSO Programming, ISPF, SDF, SDSF and PDF, FTP, TCP/IP Concepts, SNA & SNA/IP etc...

How to rewrite PDS directory stats in REXX or ISPF

Postby good123 » Tue May 03, 2011 8:35 am

I don't know to rewrite the stats for member's stats.below are portions of rexx code & ISPF library services lmmstats code
how can i keep member's stats and rewrite it to pds directory?
do any one give me some suggestions ?
thanks!

dsname = "ANQ.ETNE.PDS'
'ALLOC F(AREAD) DS('dsname') SHR REUSE
DSORG(PS) LRECL(256) RECFM(F B)'
'EXECIO * DISKR AREAD ( FINIS STEM MSTATS.'
'FREE F(AREAD)'

"EXECIO * DISKR JobTable (FINIS STEM JobName."
Job_count = 0
Do i = 1 to JobName.0
address ispexec
"lmmfind dataid("did") member("JobName.i") stats(yes)"
if rc = 0 then /* yes,found the job */
Do
JobName_out = LEFT(STRIP(JobName.i),8) /* default pad is blank */
zlchtime = zlmtime || ":" || zlmsec
out_rec = JobName_out zlcnorc zlc4date zlm4date zlchtime,
zluser zlinorc zlvers zlmod
/* SAY "OUT_REC IS :" OUT_REC */
push out_rec
address tso
"EXECIO 1 DISKW JobStats"
job_count = job_count + 1
End
good123
 
Posts: 8
Joined: Sun Jan 02, 2011 8:35 pm
Has thanked: 0 time
Been thanked: 0 time

Re: How to rewrite PDS directory stats in REXX or ISPF

Postby MrSpock » Tue May 03, 2011 8:47 am

LMMSTATS, like you mentioned. I don't quite undersand what your question is?
User avatar
MrSpock
Global moderator
 
Posts: 809
Joined: Wed Jun 06, 2007 9:37 pm
Location: Raleigh NC USA
Has thanked: 0 time
Been thanked: 4 times

Re: How to rewrite PDS directory stats in REXX or ISPF

Postby good123 » Tue May 03, 2011 11:25 am

Mrspock:
thanks.yes,i review the LMMSTATS and LMMFIND services,i got the answer.
the first,uing LMMFIND service "dialog variables"
like zlmtime 、 zlmsec 、zlmsec 、zlmnorc 、zlcnorc 、 zlc4date 、zlm4date 、 zluser 、zlinorc 、zlvers 、 zlmod to keep
them.
the second, using LMMSTATS service to set stats for each member.
vv.mm is a problem for me, it bother me many years,because i always thought about directory of pds must use assembler to
resolve it.
i have project that modify 1000 jcl ,and some string will be changed,but need to keep the member's statistics.
good123
 
Posts: 8
Joined: Sun Jan 02, 2011 8:35 pm
Has thanked: 0 time
Been thanked: 0 time

Re: How to rewrite PDS directory stats in REXX or ISPF

Postby prino » Tue May 03, 2011 11:55 am

good123 wrote:i have project that modify 1000 jcl ,and some string will be changed,but need to keep the member's statistics.
For those jobs you don't use REXX, you use PDSUPDTE.
Robert AH Prins
robert.ah.prins @ the.17+Gb.Google thingy
User avatar
prino
 
Posts: 641
Joined: Wed Mar 11, 2009 12:22 am
Location: Vilnius, Lithuania
Has thanked: 3 times
Been thanked: 29 times

Re: How to rewrite PDS directory stats in REXX or ISPF

Postby steve-myers » Tue May 03, 2011 12:05 pm

good123 wrote:...
i have project that modify 1000 jcl ,and some string will be changed,but need to keep the member's statistics.

Not a good idea. If you are altering the member, you want to update its last modification date in the directory.

I'm confused here. If you do not want to alter the directory, why on earth are you asking a question about how to alter the directory?

Other than ISPF services and programs like the Binder, few programs create user data in directory entries. While it's not difficult, I don't think I've ever seen a formal statement about the contents of the user data in an ISPF directory entry.

"...modify 1000 jcl ..." is improper terminology. You want to say "... modify 1000 JCL members ..."
steve-myers
Global moderator
 
Posts: 2105
Joined: Thu Jun 03, 2010 6:21 pm
Has thanked: 4 times
Been thanked: 243 times

Re: How to rewrite PDS directory stats in REXX or ISPF

Postby good123 » Tue May 03, 2011 1:15 pm

thank myers.
my project that choice(or select) some meber , copy original pds(PDSA) to work area(PDSB) ,and change some strings,then
write to target pds(PDSC).if REXX do not use the LM services,the member's statistics is empty,so i need to keep the original
statistics.
p.s. English not my country Language.
good123
 
Posts: 8
Joined: Sun Jan 02, 2011 8:35 pm
Has thanked: 0 time
Been thanked: 0 time


Return to TSO & ISPF

 


  • Related topics
    Replies
    Views
    Last post