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
 

 

Create GDG base from Cobol program?

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

New User


Joined: 03 Jul 2006
Posts: 53

PostPosted: Sun Jun 01, 2008 7:28 am    Post subject: Create GDG base from Cobol program?
Reply with quote

I'm not sure if it's possible.
I need to check from Cobol program if GDG base exists and if it's not I need to create it. I know that it's possible to call IDCAMS from Cobol, but can I create GDG base from Cobol using IDCAMS?

Thanks.
Back to top
View user's profile Send private message

dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Sun Jun 01, 2008 8:28 am    Post subject:
Reply with quote

Hello,

Quote:
I know that it's possible to call IDCAMS from Cobol, but can I create GDG base from Cobol using IDCAMS?
As the gdg base should be created once and used for a long tme, what business reason is there to do this in a cobol program? Even if all of the generations are deleted, the gdg base would still exist and be ready for use.

I suggest you go ahead and create the gdg base and be done with it.
Back to top
View user's profile Send private message
rmd3003

New User


Joined: 03 Jul 2006
Posts: 53

PostPosted: Sun Jun 01, 2008 10:10 am    Post subject: Reply to: Create GDG base from Cobol program????
Reply with quote

Trust me, I wouldn't be asking if it was that simple. There is no JCL - it gets generated on the fly. And GDG base name chages depending on multiple conditions. Yes, I probably can preallocate about 5000 GDG bases or just code logic in Cobol program which creates JCL and checks if GDG bases exists or not.
Back to top
View user's profile Send private message
the_gautam

Active User


Joined: 05 Jun 2005
Posts: 165
Location: Bangalore

PostPosted: Sun Jun 01, 2008 7:24 pm    Post subject:
Reply with quote

Are you sure that you need a COBOL program to allocate 5000 GDG Bases?
Quote:
And GDG base name changes depending on multiple conditions

Can we have the conditions please, which changes the GDG base names?
Back to top
View user's profile Send private message
dick scherrer

Site Director


Joined: 23 Nov 2006
Posts: 19270
Location: Inside the Matrix

PostPosted: Sun Jun 01, 2008 8:05 pm    Post subject:
Reply with quote

Hello,

Quote:
There is no JCL - it gets generated on the fly.
But if the gdg bases were already pre-defined, the generated part need only be the part of the dsn that might change from run-to-run.

You might also just call IDCAMS and "allocate" the gdg base every run. Other than the first run, it will fail, but if the error is not passed outside the calling program, it wouldn't matter.

As Gautam mentioned, we might offer better suggestions if we better understood the requirement.
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 I can not compile my program PL1 V3.R... Miguel Fernandez PL/I & Assembler 13 Tue Dec 06, 2016 8:30 pm
No new posts IMS BMP program causes 878 system abend Artemk IMS DB/DC 7 Tue Nov 22, 2016 8:26 pm


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