Portal | Manuals | References | Downloads | Info | Programs | JCLs | Mainframe wiki | Quick Ref
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
 
Opening a dynamic file

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

New User


Joined: 02 Nov 2006
Posts: 43
Location: London

PostPosted: Tue Mar 04, 2008 7:30 pm    Post subject: Opening a dynamic file
Reply with quote

Hi all,

I have an experiment in hand. I have a list of files with the same record structure which I need to open and perform the same task with.

My idea of going about this is as below:
1) Have an input parameter file that contains file locations along with file name. The record structure will be an X(80) and will contain data per row as:
c:\My Data\newfile.dat
d:\My Data\newfile2.dat

2) Open the input file within my program, read first record, open the file mentioned and start my processing.

My query is regarding the mapping from Logical to physical file name as I am aiming that to be dynamic. Can I achieve this dynamicism in my program? Any other suggestion ? I would like my input paramter file to be dynamic?
Back to top
View user's profile Send private message

Devzee

Active Member


Joined: 20 Jan 2007
Posts: 684
Location: Hollywood

PostPosted: Tue Mar 04, 2008 7:53 pm    Post subject:
Reply with quote

In which programming languauge you are experimenting.
Are you using PC or Unix COBOL or Mainframe COBOL?
Back to top
View user's profile Send private message
arien

New User


Joined: 02 Nov 2006
Posts: 43
Location: London

PostPosted: Tue Mar 04, 2008 8:49 pm    Post subject:
Reply with quote

Hi Devzee,

It is basically VMS cobol. It is fairly similar to mainframe cobol. Moreover we're working on flat files, if that is of relevance :-)
Back to top
View user's profile Send private message
arien

New User


Joined: 02 Nov 2006
Posts: 43
Location: London

PostPosted: Tue Mar 04, 2008 9:51 pm    Post subject:
Reply with quote

Hi all,

Any pointers?


Cheers,
arien icon_lol.gif
Back to top
View user's profile Send private message
enrico-sorichetti

Global Moderator


Joined: 14 Mar 2007
Posts: 10375
Location: italy

PostPosted: Tue Mar 04, 2008 11:37 pm    Post subject: Reply to: Opening a dynamic file
Reply with quote

a search on "VMS COBOL"
pointed to the HP(R) VMS cobol main documentation page
http://h71000.www7.hp.com/doc/cobol.html
and from here to the HP cobol reference manual
http://h71000.www7.hp.com/doc/82final/6296/6296pro.html

You could have done it Yourself with very little effort

and looking at the fd section guess it looks like the value of id clause might satisfy Your need
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 ISSUE IN copying Sequential file reco... thesumitk JCL & VSAM 2 Wed Dec 13, 2017 3:07 pm
No new posts File Tailoring -- Temporary dataset i... samzee71 CLIST & REXX 3 Fri Dec 01, 2017 3:12 am
No new posts Rexx - File tailoring samzee71 CLIST & REXX 10 Thu Nov 30, 2017 10:47 pm
No new posts Moving a PS file as body of a mail! Vignesh Sid JCL & VSAM 4 Tue Nov 21, 2017 9:23 pm
No new posts unable to set RC = 4 when empty file migusd SYNCSORT 1 Tue Nov 21, 2017 1:21 am

Facebook
Back to Top
 
Job Vacancies | Forum Rules | Bookmarks | Subscriptions | FAQ | Polls | Contact Us