View previous topic :: View next topic
|
Author |
Message |
nkumar
New User
Joined: 09 Mar 2008 Posts: 28 Location: USA
|
|
|
|
Hi,
SAVE is a command to get list of members, , size, change date etc in a file(userid.somename.member). (Got to know about this command in some other post in this forum)
I want to run this command in a REXX program. I have tried it using like a TSO command command but it did not work. Please help me using this command.
Basically I need to the change date and time of the members based on which i have to do further processing.
Can anyone suggest any other way to save the change date and time. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
nkumar wrote: |
SAVE is a command to get list of members, , size, change date etc in a file(userid.somename.member). (Got to know about this command in some other post in this forum) |
SAVE is a command to SAVE the data of the current session. Well, it has been at every site that I have worked in.
Quote: |
I want to run this command in a REXX program. I have tried it using like a TSO command command but it did not work. Please help me using this command. |
It did not work is rather a generic statement - could you please provide details of any messages issued.
Quote: |
Basically I need to the change date and time of the members based on which i have to do further processing. |
Do you wish to retrieve the last changed date /time or update it ?
Quote: |
Can anyone suggest any other way to save the change date and time. |
How do you mean save it ? |
|
Back to top |
|
|
nkumar
New User
Joined: 09 Mar 2008 Posts: 28 Location: USA
|
|
|
|
I wish to retrieve the last changed date and time and based on this information I have to take certain decision.
I got following error when i tried to use it like a TSO command -
IKJ56500I COMMAND SAVE NOT FOUND |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Where do you type 'SAVE' to retrieve the data and it works ? |
|
Back to top |
|
|
nkumar
New User
Joined: 09 Mar 2008 Posts: 28 Location: USA
|
|
|
|
We nned to enter the SAVE command on COMMAND LINE after entering the PDS(where member names are shown). |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
You can use SAS or REXX to interrogate the PDS directly |
|
Back to top |
|
|
superk
Global Moderator
Joined: 26 Apr 2004 Posts: 4652 Location: Raleigh, NC, USA
|
|
|
|
Nitesh, why don't we start this whole topic from the beginning. Rather than telling us what doesn't work, why don't you clearly state what it is you want to do. Nothing in your original post sounds like typical REXX or TSO/E, so you've lost me. I'm vaguely thinking that you need to call some ISPF dialog functions, but I'm not sure. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
A snippet that I have collected from somewhere
Code: |
/* REXX *** LIST A PDS AND GET THE LAST UPDATE DATE / TIME */
LIB = "your PDS name"
MEM= ' '
LMRC = 0
ADDRESS ISPEXEC
"LMINIT DATAID(PDS) DATASET('"LIB"')"
"LMOPEN DATAID("PDS")"
DO WHILE LMRC = 0
SAY MEM ZLC4DATE ZLM4DATE ZLMTIME ZLMSEC ZLUSER '.....'
"LMMLIST DATAID("PDS") OPTION(LIST) MEMBER(MEM) STATS(YES)"
LMRC=RC
END
ADDRESS ISPEXEC "LMMLIST DATAID("PDS") OPTION(FREE)"
ADDRESS ISPEXEC "LMCLOSE DATAID("PDS")"
SAY CENTER("*** END ***",80)
EXIT 0
|
|
|
Back to top |
|
|
nkumar
New User
Joined: 09 Mar 2008 Posts: 28 Location: USA
|
|
|
|
Superk,
I have a very simple query. I want to retrieve the change date & time of all the modules in a particular PDS in a PS. I will use this PS for some other processing.
Let me know if you want me to make it more simple. |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
nkumar wrote: |
Superk,
I have a very simple query. I want to retrieve the change date & time of all the modules in a particular PDS in a PS. I will use this PS for some other processing.
Let me know if you want me to make it more simple. |
Well, it would certainly have made life a lot easier if you had described your request in the way that you have just redescribed it for superk.
Getting the question exact at the firrst post is probably the most important part of your post. It took three or four Q&A sessions to get what you wanted and to be able to help you. |
|
Back to top |
|
|
nkumar
New User
Joined: 09 Mar 2008 Posts: 28 Location: USA
|
|
|
|
Thanks Expat for the code. it is perfectly working for me and this is what I was wanted.
I applogize for the initial confusion.
Thanks |
|
Back to top |
|
|
pradeepkit Warnings : 1 New User
Joined: 25 Jun 2008 Posts: 60 Location: chennai
|
|
|
|
for the same query you were having i am also struggling over here as the code given is only displaying the dates and all other stat i am not able to write into the ps please help me what code you tried |
|
Back to top |
|
|
expat
Global Moderator
Joined: 14 Mar 2007 Posts: 8797 Location: Welsh Wales
|
|
|
|
Pradeep,
Post your code and let us see why you do not get the desired results. |
|
Back to top |
|
|
nkumar
New User
Joined: 09 Mar 2008 Posts: 28 Location: USA
|
|
|
|
Hi Pradeep, Here is the part of code which I used. Might help.
Code: |
ADDRESS ISPEXEC
"LMINIT DATAID(PDS) DATASET('"LIB"')"
"LMOPEN DATAID("PDS")"
DO WHILE LMRC = 0
"LMMLIST DATAID("PDS") OPTION(LIST) MEMBER(MEM) STATS(YES)"
/*SAY MEM ZLC4DATE ZLM4DATE ZLMTIME ZLMSEC ZLUSER */
CMEMBER = " "
PARSE VAR ZLM4DATE YEAR "/" MONTH "/" DAY
PARSE VAR ZLMTIME HOUR ":" MINUTE
PARSE VAR ZLMSEC SECOND
/************************************************************/
/* COMAPRE THE CHANGE DATE OF MODULES WITH LAST UPDATE DATE */
/************************************************************/
IF YEAR > LYEAR THEN CMEMBER = MEM
ELSE DO
IF YEAR = LYEAR THEN
DO
IF MONTH > LMONTH THEN CMEMBER = MEM
ELSE DO
IF MONTH = LMONTH THEN
DO
IF DAY > LDAY THEN CMEMBER = MEM
ELSE DO
IF DAY = LDAY THEN
DO
IF HOUR > LHOUR THEN CEMEMBER = MEM
ELSE DO
IF HOUR = LHOUR THEN
DO
IF MINUTE > LMINUTE THEN
CMEMBER = MEM
ELSE DO
IF MINUTE = LMINUTE THEN
DO
IF SECOND > LSECOND THEN
CMEMBER = MEM
ELSE CMEMBER = " "
END
END
END
END
END
END
END
END
END
END
/************************************************************/
/* STORE THE MODULE IF IT IS CHANGED AFTER LAST REFRESH */
/************************************************************/
IF CMEMBER = " " | CMEMBER = 'CMEMBER' THEN NOP
ELSE
DO
M = M + 1
CMEM.M = "SRCHFOR " || "'" || CMEMBER || "'"
IF M = 1 THEN
DO
TMEM = CMEMBER
TDATE = YEAR || MONTH || DAY
TTIME = HOUR || MINUTE || SECOND
TTEMP = TDATE || TTIME
END
ELSE
DO
PMEM = CMEMBER
PDATE = YEAR || MONTH || DAY
PTIME = HOUR || MINUTE || SECOND
PTEMP = PDATE || PTIME
IF PTEMP > TTEMP THEN
DO
TMEM = PMEM
TDATE = PDATE
TTIME = PTIME
TTEMP = TDATE || TTIME
END
END
END
LMRC=RC
END
ADDRESS ISPEXEC "LMMLIST DATAID("PDS") OPTION(FREE)"
ADDRESS ISPEXEC "LMCLOSE DATAID("PDS")"
/************************************************************/
/* UPDATE CPYBOOKS WITH LAST REFRESH DATE IF ANY CHANGED */
/* MODULE IS FOUND.
/************************************************************/
IF M = 0 THEN
DO
MSG1 = " NO COPYBOOK CHANGE FOUND"
INPUT = " "
SIGNAL BEGIN
END
IF M > 0 THEN
DO
P = M + 1
CMEM.P = "/* " || TMEM " CPY ACITVE " || TDATE || " " ||TTIME
ADDRESS TSO
"ALLOC DDN(OUTFILE) DSN('NCDPNXK.ASSIGN1.SRC(CPYBOOKS)') SHR REUSE"
"EXECIO * DISKW OUTFILE(FINIS STEM CMEM."
"FREE DDN(OUTFILE)" /*- RELEASES THE DATASET */
END
|
|
|
Back to top |
|
|
smileseenu
New User
Joined: 27 Sep 2006 Posts: 13 Location: India
|
|
|
|
i tried the same with the PDS that has cobol load its not working. i need to get the load size ... |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
Please don't tag your question on to the end of a 3-year-old topic.
If you can explain what you want, what you have tried and how it is not working, you are more likely to get somewhere. |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10872 Location: italy
|
|
|
|
apart tagging on an old topic..
the question and the subject might be clear to You, but frankly , it does not make any sense to anybody else
wiser to reword it, with a proper subject description and post it to the proper forum section , REXX or ISPF |
|
Back to top |
|
|
prino
Senior Member
Joined: 07 Feb 2009 Posts: 1306 Location: Vilnius, Lithuania
|
|
|
|
(Why) Isn't there a way to automatically lock threads 1/3/6/12 months after the last post to them? |
|
Back to top |
|
|
Akatsukami
Global Moderator
Joined: 03 Oct 2009 Posts: 1788 Location: Bloomington, IL
|
|
|
|
smileseenu wrote: |
i tried the same with the PDS that has cobol load its not working. i need to get the load size ... |
Because the directory entries of load libraries are quite different from those of source libraries. |
|
Back to top |
|
|
Nic Clouston
Global Moderator
Joined: 10 May 2007 Posts: 2455 Location: Hampshire, UK
|
|
|
|
After 5 years you should know that 'its not working' is a useless piece of information. Also - you should not tag onto an old post - start a new one referencing the old one. hah - posted that before reading page 2. Duh! |
|
Back to top |
|
|
|