View previous topic :: View next topic
|
Author |
Message |
ramas.kamal
New User
Joined: 03 Mar 2014 Posts: 22 Location: India
|
|
|
|
Hi,
Request your help to put below strings side by side in output file.
Code: |
20130927021545470 BJ
140330 131231 3
|
Expected Output:
Code: |
20130927021545470 BJ140330
|
I tried below given SPLICE but unfortunately do not get expected output !
Code: |
SPLICE FROM(IN1) TO(OUT1) ON(21,1,CH) KEEPBASE WITHALL WITH(1,15) -
WITH(1,20)
|
Thanks. |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
You have a file with only two records? What is the LRECL and RECFM? |
|
Back to top |
|
|
ramas.kamal
New User
Joined: 03 Mar 2014 Posts: 22 Location: India
|
|
|
|
yes...only two records....LRECL=80,RECFM=FB |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
In INREC: IFTHEN=(WHEN=NONE, append a sequence number; IFTHEN=(WHEN=GROUP with BEGIN= for sequence number of one, and PUSH the entire record to an extension of the record.
Your output from INREC will be like this, conceptually:
Code: |
data-a 1 bbbbb
data-b 2 data-a |
With OUTFIL, have INCLUDE= for a value of two in the sequence number. Use BUILD to put the data together how you want it. |
|
Back to top |
|
|
ramas.kamal
New User
Joined: 03 Mar 2014 Posts: 22 Location: India
|
|
|
|
Bill, thank you for the idea......got the results ! |
|
Back to top |
|
|
|