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
 
changing msg or comment line in dataset to dataline usg rexx

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
subramaniabharathi

New User


Joined: 09 Mar 2006
Posts: 9

PostPosted: Tue Oct 03, 2006 2:06 pm    Post subject: changing msg or comment line in dataset to dataline usg rexx
Reply with quote

Hi,
Can anyone helpme in changing the comment line or message line in a dataset to data line

eg:
==MSG> -Warning- The UNDO command is not available until you change

this message line can be changed to data line using line command md

mdMSG> -Warning- The UNDO command is not available until you change

then the line will get changed to data line as
000001 -Warning- The UNDO command is not available until you change

now can anyone help me in running this line caommand using rexx.
(i.e) to detect all msg lines in rexx and change to data line
Back to top
View user's profile Send private message

ofer71

Global Moderator


Joined: 27 Dec 2005
Posts: 2360
Location: Israel

PostPosted: Tue Oct 03, 2006 4:14 pm    Post subject:
Reply with quote

Special lines can't be referred directly by edit macro. You can read more about it in the fine manual.

However, you can use the LOCATE SPECIAL command to locate the lines, and then use Doug Nadel's LMAC and UMAC examples to simulate the MD command.
Back to top
View user's profile Send private message
subramaniabharathi

New User


Joined: 09 Mar 2006
Posts: 9

PostPosted: Tue Oct 03, 2006 11:17 pm    Post subject: please help me in using LMAC
Reply with quote

Thank you so much ofer!

Lmac tool is good..
please tell me how to use for my purpose.I am sending you the code which I tried please correct me
I am getting the error LINEMAC not found and now whenever I open a dataset the command !LMAC is executed and says LMAC not foung.How to get rid of it.


/* REXX *******/
ADDRESS ISPEXEC
"LIBDEF ISPPLIB DATASET ID('BH0002.LMAC.LOAD')"
"LIBDEF ISPPLIB"
CALL RESETLIB
INP1='BH0002.JCLS(DB2UNLD1)'
ADDRESS ISPEXEC "EDIT DATASET('"INP1"') MACRO(JEM) MACRO (LINE)"
RETURN



/****this is the line macro*******/
/********************Rexx******/
ADDRESS ISREDIT
"ISREDIT MACRO"
"ISREDIT (LAST) = LINENUM .ZLAST"
"ISREDIT (LIN,COL) = CURSOR"
DO WHILE LIN < LAST
"ISREDIT LOCATE SPECIAL"
"ISREDIT (LIN,COL) = CURSOR"
ADDRESS ISREDIT
ISREDIT !LMAC
"LINEMAC MACRO(MD) NO PROCESS"
END



I am editing a dataset first using a macro JEM which expands the job and set some text in the special lines like message and note.
Then I am executing a macro called line which finds the last line of the dataset.and changed all special line to data line till that


Thank you so much for ur help.
SubrahmaniyaBharathi
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts line 52: Name or string > 250 char... Ashishpanpaliya CLIST & REXX 5 Sat Oct 14, 2017 2:29 am
No new posts How to write Rexx program to size and... sreejeshcs CLIST & REXX 14 Thu Oct 12, 2017 7:26 am
No new posts Copy 4 byte of data from the last rec... arunsoods DFSORT/ICETOOL 9 Fri Oct 06, 2017 12:15 pm
No new posts opening a dataset after reading it fr... arunsoods DFSORT/ICETOOL 5 Wed Oct 04, 2017 3:54 pm
This topic is locked: you cannot edit posts or make replies. Rexx to execute spool commands upendrasri CLIST & REXX 5 Wed Oct 04, 2017 6:54 am

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