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
 

 

Lines merge

 
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: Thu Mar 01, 2012 8:21 am    Post subject: Lines merge
Reply with quote

good evening everyone.

does anyone knows how to do this with dfsort (FB, LRECL 200) ?
each 3 lines should be merged into 1 line

Input
Code:
kakfjk ajaijdi aisjdi dsijisjdisjia  iajsidj iajs
AAAA asjdijsidji sa iasjidjas i aisjidjasd
BBBB asjdijsidji sa iasjidjas i aisjidjasd
asdjjd ajsijdiasjid aijs idjasidjiasjdijsaij iajsi
AAAA aoskdksaod oaksod koa oakosdk oka
BBBB oasdoka ais09idaksa oaksokdo93 ok


Output

Code:
kakfjk ajaijdi aisjdi dsijisjdisjia  iajsidj iajs AAAA asjdijsidji sa iasjidjas i aisjidjasd BBBB asjdijsidji sa iasjidjas i aisjidjasd
asdjjd ajsijdiasjid aijs idjasidjiasjdijsaij iajsi  AAAA aoskdksaod oaksod koa oakosdk oka  BBBB oasdoka ais09idaksa oaksokdo93 ok


Note: first line should be succeeded of AAAA and then BBBB
Note: first word of each first line may vary
Note: AAAA and BBBB never changes
Back to top
View user's profile Send private message

gcicchet

Senior Member


Joined: 28 Jul 2006
Posts: 1703
Location: Australia

PostPosted: Thu Mar 01, 2012 10:15 am    Post subject:
Reply with quote

Hi,

search for RESIZE (a DFSORT/ICETOOL operator)


Gerry
Back to top
View user's profile Send private message
Bill Woodger

DFSORT Moderator


Joined: 09 Mar 2011
Posts: 7307

PostPosted: Thu Mar 01, 2012 2:54 pm    Post subject: Reply to: Lines merge
Reply with quote

Do you need the records to be "concatenated" in the sense that trailing blanks on the records are to be ingored for putting them together?

If so, can you have multiple blanks embedded in the data, and if so, can we assume you'd like them retained?
Back to top
View user's profile Send private message
sqlcode1

Active Member


Joined: 08 Apr 2010
Posts: 578
Location: USA

PostPosted: Thu Mar 01, 2012 9:02 pm    Post subject:
Reply with quote

knobi,
See if below helps...

Code:
//STEP0001 EXEC PGM=ICETOOL                 
//TOOLMSG  DD  SYSOUT=*                     
//DFSMSG   DD  SYSOUT=*                     
//IN       DD  INPUT FB/200                 
//OUT      DD  OUTPUT FB/600               
//TOOLIN   DD  *                           
RESIZE FROM(IN) TO(OUT) TOLEN(600)         
/*                                         


Thanks,
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 To Merge mutliple records into a sing... anandgbe DFSORT/ICETOOL 6 Wed Feb 22, 2017 8:49 am
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 SQL Merge error -254 Robin Sulsona DB2 8 Wed Jun 01, 2016 8:28 pm
No new posts DFSORT split long VB lines efficiently BridgetBrackenbury DFSORT/ICETOOL 2 Fri Feb 12, 2016 5:10 am


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