View previous topic :: View next topic
|
Author |
Message |
narasimha.g
New User
Joined: 10 Sep 2009 Posts: 68 Location: Liverpool
|
|
|
|
Hi All,
I have a IMS database unload with over 2 million records... i now have a requirement to split the file into 3 files with around 700000 records in each file....
I can do this using the STOPAFT parameter....But there is a catch in this... I do not want the parent and child segment to get separated and go into different files....
Example....
INPUT FILE
SSP42MPR - is the parent record and SSP42SPR is the child record.
All the SSP42SPR associated records below a SSP42MPR record until the next SSP42MPR record are the child Segments.....
The number of child segments are not fixed and can be variable
Code: |
SSP42MPR...123456789QWERTY
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42SPR...892
SSP42MPR...123456789PORTYI
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42MPR...123456789PORTYI
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42SPR...892
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42SPR...892
|
Now what i want in o/p when i split is
Output 1
Code: |
SSP42MPR...123456789QWERTY
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42SPR...892
SSP42MPR...123456789PORTYI
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
|
Output 2
Code: |
SSP42MPR...123456789PORTYI
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42SPR...892
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42SPR...892
|
and not
Output 1
Code: |
SSP42MPR...123456789QWERTY
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42SPR...892
SSP42MPR...123456789PORTYI
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42MPR...123456789PORTYI
SSP42SPR...898
SSP42SPR...899
|
Output 2
Code: |
SSP42SPR...891
SSP42SPR...892
SSP42SPR...898
SSP42SPR...899
SSP42SPR...891
SSP42SPR...892
|
I want the split record count to be somewhere around 700000 not very specific abt the count.....
Could you please help me in doing this.... |
|
Back to top |
|
|
Bill Woodger
Moderator Emeritus
Joined: 09 Mar 2011 Posts: 7309 Location: Inside the Matrix
|
|
|
|
If you have your whole file, browse it. Go to about 700000th record. Visually identify next logical position to break file. Go down another 700000. Repeat. Hope that you remembered, or wrote down, the exact numbers.
Then you have some start/stop numbers for whatever method you choose to simply split the file. |
|
Back to top |
|
|
Escapa
Senior Member
Joined: 16 Feb 2007 Posts: 1399 Location: IL, USA
|
|
|
|
Can you please confirm if you have DFSORT or SYNCSORT?
Also what is LRECL and RECFM of the file? |
|
Back to top |
|
|
enrico-sorichetti
Superior Member
Joined: 14 Mar 2007 Posts: 10873 Location: italy
|
|
|
|
given the frequency of Your posts ...
isn ' t it time for Your organization to use the servics of a paid consultant
instead of relying on free consultancy from public forum ?
looks like You and You company do not have a bit of ethics !
or maybe that' s Your way of doing business ??? |
|
Back to top |
|
|
narasimha.g
New User
Joined: 10 Sep 2009 Posts: 68 Location: Liverpool
|
|
|
|
Escapa wrote: |
Can you please confirm if you have DFSORT or SYNCSORT?
Also what is LRECL and RECFM of the file? |
Sorry forgot to mention this...
RECFM is VB
LRECL 2004 |
|
Back to top |
|
|
Escapa
Senior Member
Joined: 16 Feb 2007 Posts: 1399 Location: IL, USA
|
|
|
|
narasimha.g wrote: |
Escapa wrote: |
Can you please confirm if you have DFSORT or SYNCSORT?
Also what is LRECL and RECFM of the file? |
Sorry forgot to mention this...
RECFM is VB
LRECL 2004 |
YOU DID NOT ANSWER MY FIRST QUESTION? |
|
Back to top |
|
|
narasimha.g
New User
Joined: 10 Sep 2009 Posts: 68 Location: Liverpool
|
|
|
|
enrico-sorichetti wrote: |
given the frequency of Your posts ...
isn ' t it time for Your organization to use the servics of a paid consultant
instead of relying on free consultancy from public forum ?
looks like You and You company do not have a bit of ethics !
or maybe that' s Your way of doing business ??? |
I have been member since 2 years never asked so many questions.... its just that I am more in need now and usually rely on this forum for any mainframe help.... Nothing to do with the company ethics.... Anyways Thanks for the Help |
|
Back to top |
|
|
narasimha.g
New User
Joined: 10 Sep 2009 Posts: 68 Location: Liverpool
|
|
|
|
Bill Woodger wrote: |
If you have your whole file, browse it. Go to about 700000th record. Visually identify next logical position to break file. Go down another 700000. Repeat. Hope that you remembered, or wrote down, the exact numbers.
Then you have some start/stop numbers for whatever method you choose to simply split the file. |
Thanks very much Bill.... Very helpful for an one off solution.... ll try that.... |
|
Back to top |
|
|
narasimha.g
New User
Joined: 10 Sep 2009 Posts: 68 Location: Liverpool
|
|
|
|
Escapa wrote: |
narasimha.g wrote: |
Escapa wrote: |
Can you please confirm if you have DFSORT or SYNCSORT?
Also what is LRECL and RECFM of the file? |
Sorry forgot to mention this...
RECFM is VB
LRECL 2004 |
YOU DID NOT ANSWER MY FIRST QUESTION? |
I have SYNCSORT here.... |
|
Back to top |
|
|
dick scherrer
Moderator Emeritus
Joined: 23 Nov 2006 Posts: 19244 Location: Inside the Matrix
|
|
|
|
Hello
Quote: |
I have SYNCSORT here.... |
Which release? This is at the top of the informational output generated for each run.
The release may influence which solution(s) might be available to meet your requirement. |
|
Back to top |
|
|
narasimha.g
New User
Joined: 10 Sep 2009 Posts: 68 Location: Liverpool
|
|
|
|
dick scherrer wrote: |
Hello
Quote: |
I have SYNCSORT here.... |
Which release? This is at the top of the informational output generated for each run.
The release may influence which solution(s) might be available to meet your requirement. |
its SYNCSORT FOR Z/OS 1.3.1.1R.... |
|
Back to top |
|
|
|