Portal | Manuals | References | Downloads | Info | Programs | JCLs | Master the Mainframes
IBM Mainframe Computers Forums Index
 
Register
 
IBM Mainframe Computers Forums Index Mainframe: Search IBM Mainframe Forum: FAQ Memberlist Usergroups Profile Log in to check your private messages Log in
 

 

Deleting some lines in a Dataset using Clist

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> CLIST & REXX
View previous topic :: :: View next topic  
Author Message
ravikumar15

New User


Joined: 27 Mar 2006
Posts: 64

PostPosted: Wed Sep 23, 2009 5:01 pm    Post subject: Deleting some lines in a Dataset using Clist
Reply with quote

Hi,

I have a requirement, based on the users input, we need to delete some lines from a dataset. Is there any command in Clist/ ISPF to delete some lines from the given dataset.

Thanks in advance.
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Wed Sep 23, 2009 5:28 pm    Post subject: Reply to: Deleting some lines in a Dataset using Clist
Reply with quote

there are many ways of doing it, depending on ...

how clear are the requirements
how to identify the lines to delete
what kind of user interface
the size of the dataset

the ISPF dialog might be simple if the arguments to be used for the task
can fit in one screen

then depending on the dataset size
1) edit in place ( after a backup )
2) submit a <sort> job to do it

but I would never use a clist, only REXX, REXX, REXX, ...
Back to top
View user's profile Send private message
Pedro

Senior Member


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

PostPosted: Wed Sep 23, 2009 9:03 pm    Post subject: Reply to: Deleting some lines in a Dataset using Clist
Reply with quote

Quote:
if the arguments to be used for the task
can fit in one screen


You can define a scrollable area in a panel to get more than 24 lines on a screen.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10211
Location: italy

PostPosted: Wed Sep 23, 2009 9:06 pm    Post subject: Reply to: Deleting some lines in a Dataset using Clist
Reply with quote

Quote:
You can define a scrollable area in a panel to get more than 24 lines on a screen.

easy for the output, bit more complicated ( if not impossible ) for the input
( I am rather inclined for the impossible )
Back to top
View user's profile Send private message
Pedro

Senior Member


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

PostPosted: Thu Sep 24, 2009 1:35 am    Post subject: Reply to: Deleting some lines in a Dataset using Clist
Reply with quote

Actually, it is pretty easy. You can convert pretty much any standard panel with three additional lines. See the example.

Code:
)PANEL KEYLIST(ISPTEST,ISP)                                         
)ATTR                                                               
 ` AREA(SCRL) EXTEND(ON)                                           
 ~ TYPE(text) COLOR(blue) INTENS(high)                             
 @ TYPE(text) COLOR(green) INTENS(high)                             
 ¢ TYPE(OUTPUT) COLOR(GREEN) INTENS(LOW)                           
 # TYPE(input) COLOR(TURQ) INTENS(HIGH) hilite(uscore)             
 ¬ TYPE(text) COLOR(TURQ) INTENS(HIGH)                             
 ? TYPE(TEXT) COLOR(WHITE) INTENS(HIGH) HILITE(USCORE)             
)BODY EXPAND(//)                                                   
%Help +                                                             
~/-/+                                                               
~toolname/ /Application Fields      / /                             
@Command ===>#ZCMD                                                 
                                                                   
`SAREA39                                                           
)AREA SAREA39                                                       
@Fill in the fields below.                                         
                                                                   
@Field 1 . . . .#f1          +                                     
@Field 2 . . . .#f2          +                                     
@Field 3 . . . .#f3          +                                                                     
@Field 9 . . . .#f9          + repeat lines       
)END                                                               


You can add more data lines to see the effect, or split screen to make the 'screen' smaller.

The three lines:
1. attribute for AREA(SCRL)
2. line with use of that attribute
3. )AREA tag. everything after that tag is scrollable. I think you can have at least 400 lines.

actually, I said 'screen' in my earlier post, but meant to describe the panel data, not the physical screen.
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 -> CLIST & REXX All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts syncsort: copy lines after the keyword shreya19 SYNCSORT 7 Fri Dec 02, 2016 9:47 am
No new posts What is the code in CLIST to enable t... jackzhang75 CLIST & REXX 1 Fri Dec 02, 2016 3:02 am
No new posts FTP - JCL failed while passing FTP co... Suneetha1612 JCL & VSAM 12 Wed Nov 16, 2016 7:33 pm
No new posts To trim spaces in a pipe delimited da... Nish84 COBOL Programming 16 Mon Oct 10, 2016 1:54 pm
No new posts Allocate dataset withour BLKSIZE Susanta CLIST & REXX 2 Thu Sep 22, 2016 11:51 am


Facebook
Back to Top
 
Mainframe Wiki | Forum Rules | Bookmarks | Subscriptions | FAQ | Tutorials | Contact Us