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
 

 

Dynamic file processing , in COBOL

 
Post new topic   Reply to topic    IBMMAINFRAMES.com Support Forums -> COBOL Programming
View previous topic :: :: View next topic  
Author Message
Ranjithkumar

New User


Joined: 10 Sep 2008
Posts: 94
Location: India

PostPosted: Thu Mar 11, 2010 3:14 pm    Post subject: Dynamic file processing , in COBOL
Reply with quote

I know it is possible to allocate files dynamically in COBOL. I need to know is it possible to open/edit/close these dynamically allocated files in COBOL, without using any ASSEMBLER routine. Please suggest me if it is possible.
Back to top
View user's profile Send private message

Mathiv Anan

Active User


Joined: 23 Jul 2008
Posts: 106
Location: USA

PostPosted: Thu Mar 11, 2010 3:22 pm    Post subject: Reply to: Dynamic file processing , in COBOL
Reply with quote

Hi Ranjithkumar,

Is this COBOL question?

There are number of discussions occurred in this forum on dynamic file allocation.

one of them is :

http://www.ibmmainframes.com/viewtopic.php?t=46689&highlight=

You can search and learn a lot on this topic..

BTW.. your question is not clear..

Can you please state your requirement clearly?
Back to top
View user's profile Send private message
Ranjithkumar

New User


Joined: 10 Sep 2008
Posts: 94
Location: India

PostPosted: Thu Mar 11, 2010 3:27 pm    Post subject: Reply to: Dynamic file processing , in COBOL
Reply with quote

I have a huge file , which i need to split into files having 50k records each. The record count of input file may vary . I need a standard process to do this splitting. Suggest me if any other option is available to do this.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Thu Mar 11, 2010 4:35 pm    Post subject:
Reply with quote

SORT can be your choice to split the file, however you need to tell teh rules and LRECL/RECFM of the input and output files.
Back to top
View user's profile Send private message
Ranjithkumar

New User


Joined: 10 Sep 2008
Posts: 94
Location: India

PostPosted: Thu Mar 11, 2010 4:51 pm    Post subject: Reply to: Dynamic file processing , in COBOL
Reply with quote

There are no rules for splitiing the file. The file is FB / 2000. If i use a SORT routine, I have to modify it every time. For eg. When the input file has 500K records , i have to specify 10 output files in the SORT step. But the next time the input file may have 1000K records. This time i cannot use the same SORT since i need 20 output files. I need to split the files using a process , irrespective of the record count. I have achieved this using ASSEMBLER . But I need some other option , other than ASSEMBLER.
Back to top
View user's profile Send private message
Anuj Dhawan

Senior Member


Joined: 22 Apr 2006
Posts: 6258
Location: Mumbai, India

PostPosted: Thu Mar 11, 2010 5:01 pm    Post subject:
Reply with quote

This link has similar problem discussed some time back, a work around it should give you a working model for your requirement.
Back to top
View user's profile Send private message
Ranjithkumar

New User


Joined: 10 Sep 2008
Posts: 94
Location: India

PostPosted: Thu Mar 11, 2010 5:54 pm    Post subject: Reply to: Dynamic file processing , in COBOL
Reply with quote

Hi Anuj, The JCL present in the link splits file based on the INCLUDE condition. In my case there is no condition. I have to split the files based on record count only. Each file should have 50k records.
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 -> COBOL Programming All times are GMT + 6 Hours
Page 1 of 1

 

Search our Forum:

Similar Topics
Topic Author Forum Replies Posted
No new posts Executing OO COBOL program invoking J... Virendra Shambharkar COBOL Programming 2 Tue Jan 10, 2017 6:37 pm
No new posts OO COBOL compile error Virendra Shambharkar COBOL Programming 3 Tue Jan 10, 2017 6:05 pm
No new posts Need Suggestion on COBOL program vickey_dw COBOL Programming 5 Thu Jan 05, 2017 10:55 pm
No new posts Copy RECFM =VB TO FB file with RECL =... sahil41352 DFSORT/ICETOOL 3 Wed Dec 28, 2016 11:29 pm
No new posts REXX DB2: Dynamic allocation of DB2.D... BHAS CLIST & REXX 3 Mon Dec 19, 2016 8:26 pm


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