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
 
ISPF macro - Changing only non excluded lines

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

New User


Joined: 29 May 2006
Posts: 59
Location: India

PostPosted: Thu Aug 21, 2008 9:52 pm    Post subject: ISPF macro - Changing only non excluded lines
Reply with quote

Hi all,

Using ISREDIT macro, I just want to change the high level qualifier of a production dataset name to test name. I can do that as per below code

Code:
ISREDIT C 'PROD#P'  'TEST#T'  ALL


But how will I change all these occurances only for non excluded lines.
Basically I dont want to make a change for comments. So first i can exclude the comments using
Code:
ISREDIT EXCLUDE "//*" 1 ALL


But how will I make a change only for non excluded lines.

Thanks
Chidam
Back to top
View user's profile Send private message

superk

Moderator Team Head


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

PostPosted: Thu Aug 21, 2008 9:54 pm    Post subject: Reply to: ISPF macro - Changing only non excluded lines
Reply with quote

Didn't

ISREDIT C 'PROD#P' 'TEST#T' NX ALL

work?
Back to top
View user's profile Send private message
Pedro

Senior Member


Joined: 01 Sep 2006
Posts: 2086
Location: Silicon Valley

PostPosted: Thu Aug 21, 2008 10:00 pm    Post subject: Reply to: ISPF macro - Changing only non excluded lines
Reply with quote

Quote:
Basically I dont want to make a change for comments.

It seems to me that the documentation (comments) would be wrong then.
Back to top
View user's profile Send private message
chidams78
Currently Banned

New User


Joined: 29 May 2006
Posts: 59
Location: India

PostPosted: Thu Aug 21, 2008 10:00 pm    Post subject:
Reply with quote

Earlier I had put the REXX macro code as
Code:
"ISREDIT" C 'PROD#P' 'TEST#T' "NX" ALL


But the correct one is as you had specified
Code:
"ISREDIT C 'PROD#P' 'TEST#T' NX ALL"


This one is working..Cool..thanks superk
Back to top
View user's profile Send private message
chidams78
Currently Banned

New User


Joined: 29 May 2006
Posts: 59
Location: India

PostPosted: Fri Aug 22, 2008 9:21 pm    Post subject:
Reply with quote

Hi all,

Is there any command to get the info from the line command region

For example, if I want to know how many lines got changed after executing the ISPF REXX macro (changing high level qualifier), I am thinking of reading the data on the left side of each impacted line(==CHG> ). Then take the occurances of it.
Could you please help me how to go for that OR is there any other logic to do that

Chidams
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8167
Location: East Dubuque, Illinois, USA

PostPosted: Fri Aug 22, 2008 9:26 pm    Post subject:
Reply with quote

Code:
ISREDIT (CHGED) = CHANGE_COUNTS
Back to top
View user's profile Send private message
chidams78
Currently Banned

New User


Joined: 29 May 2006
Posts: 59
Location: India

PostPosted: Sat Aug 23, 2008 1:22 am    Post subject:
Reply with quote

Hi Robert,

Thanks for the command.

The above mentioned command will give the number of times the changes were put in the line.

If a single line has encountered changes for 5 times, this will give the number as 5. But I want to know how many lines got changed irrespective of the number of times, a line has undergone changes.
Back to top
View user's profile Send private message
dbzTHEdinosauer

Global Moderator


Joined: 20 Oct 2006
Posts: 6968
Location: porcelain throne

PostPosted: Sat Aug 23, 2008 4:04 am    Post subject:
Reply with quote

chidams78,
you have been mis-informed.

change_counts returns the
number of lines
that have been affected by the
last CHANGE command
Back to top
View user's profile Send private message
chidams78
Currently Banned

New User


Joined: 29 May 2006
Posts: 59
Location: India

PostPosted: Mon Aug 25, 2008 9:20 pm    Post subject:
Reply with quote

I was looking for the number of lines changed.
But what i got in the change_counts variable is the number of times the lines had undergone changes. In the below example i got change_counts as 3 (3 times the single line got changed) instead of 1.

Eg: I had 20 lines in the PROC and my macro will change the prod qualifiers to test qualifiers for the datasets and its properties.

Before change
//SORTOUT DD DSN=PRD#PP.PRDFLE.FILE,DISP=(,CATLG,DELETE),

After change
//SORTOUT DD DSN=TST#TT.TESTFLE.AUG23,DISP=(,CATLG,DELETE),

PRD#PP is to be changed to TST#TT
PRDFLE --> TESTFLE
FILE --> AUG23

Plz help....
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 MQ command in option 6 of ISPF! Vignesh Sid All Other Mainframe Topics 3 Tue Sep 26, 2017 6:01 pm
No new posts Assembler Macro Copybook converted to... Ziquilix PL/I & Assembler 4 Tue Sep 26, 2017 3:07 am
No new posts exec macro in the end of edit anatol CLIST & REXX 8 Fri Sep 22, 2017 5:10 am
No new posts Conditional highlighting of rows in I... packerm CLIST & REXX 2 Thu Sep 21, 2017 6:50 pm
No new posts Creating ISPF Screens with Scrname vi... Albireo20 TSO/ISPF 10 Tue Sep 05, 2017 4:24 pm

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