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
 

 

Combine groups of lines in one line

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> DFSORT/ICETOOL
View previous topic :: :: View next topic  
Author Message
knobi

New User


Joined: 16 Aug 2005
Posts: 46

PostPosted: Fri Jun 20, 2014 3:43 am    Post subject: Combine groups of lines in one line
Reply with quote

hello, would be possible to this with sort ?

Basically, retrieve only the groups of 4 lines and merge the lines one after the other.

Input:
Code:

lines...before/after
cccc blablabla
    zzzz blabla
    yyyy blabla
    aaaa blabla
    bbbb blabla
lines...before/after
cccc blablabla
    zzzz blabla
    yyyy blabla
    aaaa blabla
    bbbb blabla
lines...before/after


Code:

cccc blablabla     zzzz blabla    yyyy blabla    aaaa blabla    bbbb blabla
cccc blablabla     zzzz blabla    yyyy blabla    aaaa blabla    bbbb blabla
Back to top
View user's profile Send private message

knobi

New User


Joined: 16 Aug 2005
Posts: 46

PostPosted: Fri Jun 20, 2014 5:27 am    Post subject: Reply to: Combine groups of lines in one line
Reply with quote

small correction.. this are 5 lines groups...
and the second piece of code, from the above post is how would be the output.
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7241

PostPosted: Fri Jun 20, 2014 5:49 am    Post subject: Reply to: Combine groups of lines in one line
Reply with quote

Yes, if you can identify them sufficiently.

Look at ICETOOL's RESIZE operator. OMIT COND= for the stuff you don't want (or INCLUDE COND= for the stuff you want) in a USING which also includes an OUTFIL for your final processing.

Search for RESIZE examples. If you get stuck, show us what you've done and we should be able to move you on with it.
Back to top
View user's profile Send private message
knobi

New User


Joined: 16 Aug 2005
Posts: 46

PostPosted: Fri Jun 20, 2014 5:52 am    Post subject:
Reply with quote

i was trying to fit the code below on my jcl.. but not too much lucky so far...
any advise would be great

INREC IFTHEN=(WHEN=INIT,

OVERLAY=(134:SEQNUM,8,ZD)),
IFTHEN=(WHEN=(2,7,CH,EQ,C'WARNING'),
OVERLAY=(142:SEQNUM,8,ZD,
134:134,8,ZD,SUB,142,8,ZD,M11,LENGTH=8)),


IFTHEN=(WHEN=NONE,
OVERLAY=(134:SEQNUM,8,ZD))
Back to top
View user's profile Send private message
knobi

New User


Joined: 16 Aug 2005
Posts: 46

PostPosted: Fri Jun 20, 2014 6:08 am    Post subject:
Reply with quote

i'm little behind on icetool... wasn't aware of resize... worked pretty good !
thanks !
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7241

PostPosted: Fri Jun 20, 2014 11:26 am    Post subject: Reply to: Combine groups of lines in one line
Reply with quote

Well, at just 19 minutes after my suggestion, you're catching up fast. Good work.

If you can post your solution, it may help others with a similar requirement.
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 -> DFSORT/ICETOOL 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 Insert Lines in JCL with Rexx after a... Willy Jensen CLIST & REXX 3 Tue Aug 30, 2016 4:18 pm
No new posts Combine columns without breaking words Indrajit_57 SYNCSORT 1 Sat Mar 19, 2016 9:33 am
No new posts DFSORT split long VB lines efficiently BridgetBrackenbury DFSORT/ICETOOL 2 Fri Feb 12, 2016 5:10 am
No new posts DFSORT VB File make 2 lines from 1 BridgetBrackenbury DFSORT/ICETOOL 2 Fri Feb 12, 2016 3:48 am


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