Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Profile Log in to check your private messages Log in
 
Macro called when save in edit

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> TSO/ISPF
View previous topic :: :: View next topic  
Author Message
Philippe

New User


Joined: 10 Jan 2008
Posts: 15
Location: France

PostPosted: Thu Jan 17, 2008 2:57 pm    Post subject: Macro called when save in edit
Reply with quote

I want to execute a isredit macro each time users save a file.
Why ?
Because we want to record in a history file, each modification user does on sensibles system files (parmlib, proclib etc ...)

Thanks a lot for any help !
Phil
Back to top
View user's profile Send private message

ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Thu Jan 17, 2008 3:10 pm    Post subject:
Reply with quote

You can use an organizational initial macro that uses the DEFINE command. Read the fine manuals for more info.

O.
Back to top
View user's profile Send private message
Philippe

New User


Joined: 10 Jan 2008
Posts: 15
Location: France

PostPosted: Thu Jan 17, 2008 6:22 pm    Post subject:
Reply with quote

Thank a lot ofer71
I knew this possibility wich is ok if user put "SAVE" on line command but if user leave the file with END (pf3 for example), he doesn't pass to the alias defined by the DEFINE, even if the END generate a SAVE.
It's the same if I code a DEFINE on the END command

We only want to record changes on particular datasets

Thank again
Phil
Back to top
View user's profile Send private message
stodolas

Active Member


Joined: 13 Jun 2007
Posts: 632
Location: Wisconsin

PostPosted: Thu Jan 17, 2008 6:23 pm    Post subject:
Reply with quote

That data is already stored on your system in the SMF records. Why reinvent the wheel.
Back to top
View user's profile Send private message
Philippe

New User


Joined: 10 Jan 2008
Posts: 15
Location: France

PostPosted: Thu Jan 17, 2008 6:29 pm    Post subject:
Reply with quote

stodolas,

of course the data is already stored into smf records but I have to explain all the process I want install and why I can't use smf

I want to force users who modify sensible datasets, to write a comment on a history file where you have date, time, user, dataset, member and a brief description of the change.

Philippe
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10308
Location: italy

PostPosted: Thu Jan 17, 2008 6:33 pm    Post subject: Reply to: Macro called when save in edit
Reply with quote

If You need to keep track of the changes made to every member, then it would be more practical to use a change management tool;
I have used SCLM for that, with a little planning it works nicely
( i had a simple setup only for versioning and auditing, not for the full
blown application management- checkout/build/promote )

to audit each user activity You might want to process the ISPF logs

if I remember correctly smf will not record the member names, just open close
activities for the dataset ( I might be wrong )
Back to top
View user's profile Send private message
Philippe

New User


Joined: 10 Jan 2008
Posts: 15
Location: France

PostPosted: Thu Jan 17, 2008 6:48 pm    Post subject:
Reply with quote

Hi enrico,

good idea for sclm but we don't use this fonction.
We only use basic ispf interface and the target of my solution must be transparent for user
We don't want to audit user activity but only have a trace with a description of changes made on particular datasets

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

Global Moderator


Joined: 14 Mar 2007
Posts: 10308
Location: italy

PostPosted: Thu Jan 17, 2008 6:59 pm    Post subject: Reply to: Macro called when save in edit
Reply with quote

I would say that it might be simpler to do it in an initial macro...
You might have a little more traffic on the audit/versioning dataset
but the implementation might be much_much simpler

save the current member to ....

display a screen asking for change info

insert the lines into the file being edited

exit the macro and hope...

the only issue might be when the user does not save the dataset

doing things at the beginning might be a catch all approach

still will not protect from actions like

open a dummy member

copy the original
edit the data
replace the original
cancel

unless You want to muck around with the ispf exits ....
Back to top
View user's profile Send private message
Philippe

New User


Joined: 10 Jan 2008
Posts: 15
Location: France

PostPosted: Thu Jan 17, 2008 8:20 pm    Post subject:
Reply with quote

I don't see anything on the 16 exit points of ispf
After your differents ideas, I think I will continue on my first approach (and ofer71) but I have to define an alias on END command.
But it will be difficult to know in the imacro if the data have been changed

If someone has an idea ...

Thank and Regards,
Philippe
Back to top
View user's profile Send private message
ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Thu Jan 17, 2008 8:31 pm    Post subject:
Reply with quote

You can use the DATA_CHANGED command.

O.
Back to top
View user's profile Send private message
Philippe

New User


Joined: 10 Jan 2008
Posts: 15
Location: France

PostPosted: Thu Jan 17, 2008 8:51 pm    Post subject:
Reply with quote

I think you have my solution ofer71 !
I will test it and I will come back to give you the result

Thank a lot
Philippe
Back to top
View user's profile Send private message
Marso

REXX Moderator


Joined: 13 Mar 2006
Posts: 1243
Location: Israel

PostPosted: Thu Jan 17, 2008 10:18 pm    Post subject:
Reply with quote

Philippe, bienvenue au forum!

About the END problem, the use of AUTOSAVE OFF PROMPT will force the user to SAVE or CANCEL if data has changed.
that may be a good option.
Back to top
View user's profile Send private message
Philippe

New User


Joined: 10 Jan 2008
Posts: 15
Location: France

PostPosted: Fri Jan 18, 2008 1:13 pm    Post subject:
Reply with quote

That a new good idea Marso, and just before exit the macro I could restore the original option AUTOSAVE
Thank you
I have some tests to valid today

Best Regards
Philippe
Back to top
View user's profile Send private message
Philippe

New User


Joined: 10 Jan 2008
Posts: 15
Location: France

PostPosted: Fri Jan 18, 2008 8:18 pm    Post subject:
Reply with quote

It's ok with the excellent idea of ofer71 (DATA_CHANGED)
I did an alias on SAVE and END (the same) and with the test it's ok

Now I want to implement it on an IMACRO but at the begining of the TSO session (first rexx pointef by parm on the logon procedure) to install it only on profile for special users
I tried with IMACRO statment and with ZUSERMAC variable but without success ...
Thank's for your help

Regards and have a nice week end !
Philippe
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 -> TSO/ISPF All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts LIBDEF not working in called proc packerm CLIST & REXX 0 Fri Sep 15, 2017 7:22 pm
No new posts How to Run Rexx Macro? Kalaivignesh CLIST & REXX 5 Fri Sep 01, 2017 9:08 pm
No new posts ISREDIT MACRO NOT WORKING! :cry: kirank889 TSO/ISPF 3 Thu Aug 03, 2017 5:46 pm
This topic is locked: you cannot edit posts or make replies. How to save expanded jcl's into one l... enrico-sorichetti CLIST & REXX 13 Thu Jul 27, 2017 2:45 pm
No new posts Could we identify the called modules ... elixir1986 COBOL Programming 5 Fri Jul 14, 2017 1:53 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us