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 Profile Log in to check your private messages Log in
 
SYNCSORT Split the file based on the count

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> JCL & VSAM
View previous topic :: :: View next topic  
Author Message
itzphaniz

New User


Joined: 02 Sep 2005
Posts: 39

PostPosted: Wed Mar 12, 2008 11:35 am    Post subject: SYNCSORT Split the file based on the count
Reply with quote

Hi,

I have a file: "CountFile" with say some 10000 records [This count is not fixed]

I would like to split "CountFile" in to 104 files with same record count in each of this file.So now we have approximately 96-97 records in each of this 104 files.

Here only the number of records in "CountFile" is dynamic. And 104 is fixed.

Any help would be deeply appreciated.
Back to top
View user's profile Send private message

enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10308
Location: italy

PostPosted: Wed Mar 12, 2008 11:55 am    Post subject: Reply to: SYNCSORT Split the file based on the count
Reply with quote

Just curious,
this is one of the many posts were it is asked how to split a file based only on the record count

what is the business/application logic behind this
usually the record in a dataset have some common properties,
why , in this case, the 58th record should be treated in a different way from the 110th ???
Back to top
View user's profile Send private message
itzphaniz

New User


Joined: 02 Sep 2005
Posts: 39

PostPosted: Wed Mar 12, 2008 12:20 pm    Post subject:
Reply with quote

enrico-

104 = 2*52Weeks i.e. for two years. We are not treating the 58, 110th record differently. It is just that they will be in a separate file while loading in to our DB. After loading, 58 and 110th record will retain their significance icon_smile.gif. I'm not sure if i understood your question.
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10308
Location: italy

PostPosted: Wed Mar 12, 2008 12:45 pm    Post subject: Reply to: SYNCSORT Split the file based on the count
Reply with quote

so after all the common property of the records in a dataset is the week
and the 58th record has a different property from the 110th ( they belong to different weeks)

still, I feel it would be safer to split on the value of a field rather than on the number of the records... what if icon_smile.gif icon_question.gif

in a standards/practices/process assurance/review, the auditors would certainly point it out
and make a strong suggestion to change the process ( seen it, done it ) icon_biggrin.gif
Back to top
View user's profile Send private message
itzphaniz

New User


Joined: 02 Sep 2005
Posts: 39

PostPosted: Wed Mar 12, 2008 2:51 pm    Post subject:
Reply with quote

All,

With the help of DFSORT technique, I'm able to split the file.
Here is my SYSIN:

Code:
  SORT FIELDS=(24,10,CH,A)                   
  OUTFIL FNAMES=(OUT1,OUT2,OUT3,OUT4),SPLIT


Thanks for any effort you guys have put in!!
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 -> JCL & VSAM All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts column with count of rows within dist... ronald wouterson DB2 4 Sun Sep 17, 2017 9:48 pm
No new posts Split 1 file into 10 output Files - S... Prasanth Kumar SYNCSORT 5 Sat Sep 16, 2017 12:02 am
No new posts BUILD OUTFIL based on condition other... balaji81_k DFSORT/ICETOOL 13 Fri Sep 08, 2017 11:06 pm
No new posts Updating the Trailer count in variabl... satheshbabur DFSORT/ICETOOL 6 Wed Aug 30, 2017 9:49 pm
No new posts SORT Trailer Count - LRECL Output co... amorante DFSORT/ICETOOL 5 Tue Aug 29, 2017 8:57 pm

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