IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

can we read a dataset without a FCT entry in cics-cobol prog


IBM Mainframe Forums -> CICS
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
bhuspin

New User


Joined: 13 Aug 2008
Posts: 26
Location: chennai

PostPosted: Fri Nov 14, 2008 10:23 am
Reply with quote

Can we read a dataset using a cobol program, the condition is the dataset doesn't have a FCT entry in cics-cobol program
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


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

PostPosted: Fri Nov 14, 2008 10:50 am
Reply with quote

Hello,

No. . .

Why is this an issue for your requirement?
Back to top
View user's profile Send private message
bhuspin

New User


Joined: 13 Aug 2008
Posts: 26
Location: chennai

PostPosted: Fri Nov 14, 2008 12:52 pm
Reply with quote

ok thanks DICK
Back to top
View user's profile Send private message
namitjai

New User


Joined: 12 Feb 2008
Posts: 41
Location: Bangalore

PostPosted: Fri Nov 14, 2008 4:05 pm
Reply with quote

Hi,
Can a cobol-cics program(pgm1) call a cobol program which is not a cics program(pgm2) and is reading a flat file.
If its possible than how are we going to make entry of flat file used by pgm2 into FCT.
If its not possible than can pgm1 call pgm2 where pgm2 is using a vsam file instead of flat file.

Also can pgm2 read the file using READ FILE command or it has to use EXEC CICS READ(file) command.

Thanks,
Back to top
View user's profile Send private message
Garry Carroll

Senior Member


Joined: 08 May 2006
Posts: 1193
Location: Dublin, Ireland

PostPosted: Fri Nov 14, 2008 6:04 pm
Reply with quote

The only supported way to read a flat file in CICS is by defining it as extra-partition TD queue. Do NOT try to use non-CICS means to access files.

Garry.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Fri Nov 14, 2008 6:37 pm
Reply with quote

Quote:
Can a cobol-cics program(pgm1) call a cobol program which is not a cics program(pgm2) and is reading a flat file.
If its possible than how are we going to make entry of flat file used by pgm2 into FCT.
If its not possible than can pgm1 call pgm2 where pgm2 is using a vsam file instead of flat file.

Also can pgm2 read the file using READ FILE command or it has to use EXEC CICS READ(file) command.
Oracle Robert's prediction: there's a CICS region on its way down sometime soon.

Flat files can be extrapartition transient data queues. They cannot be added to an FCT.

A CICS COBOL program can call a COBOL program. If the called program attempts to do anything with a file (such as OPEN it), the called program will abend and it might take the entire CICS region down with it. CICS does not play well with the operating system functions inherent in the OPEN macro used by COBOL.

You have several choices: (1) convert the file being read by the called program into a table in the program, (2) remove all file logic from the called program and change the READ to READQ TD so the flat file can be added as a TDQ to the region, (3) convert the flat file to a VSAM file, add the VSAM file to the FCT, remove the called program file logic and replace the READ with a CICS READ command, or (4) figure out a way to do your function outside of CICS.
Back to top
View user's profile Send private message
namitjai

New User


Joined: 12 Feb 2008
Posts: 41
Location: Bangalore

PostPosted: Fri Nov 14, 2008 6:55 pm
Reply with quote

So that means that a Cics cobol program will not be able to call a normal cobol program(no cics commands) which is performing READ file command.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8696
Location: Dubuque, Iowa, USA

PostPosted: Fri Nov 14, 2008 7:00 pm
Reply with quote

Correct -- but if the called COBOL program has no file I/O commands in it, there is no problem with CICS programs calling COBOL programs.
Back to top
View user's profile Send private message
namitjai

New User


Joined: 12 Feb 2008
Posts: 41
Location: Bangalore

PostPosted: Fri Nov 14, 2008 7:14 pm
Reply with quote

That answers to my question

Thanks,
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> CICS

 


Similar Topics
Topic Forum Replies
No new posts Replace each space in cobol string wi... COBOL Programming 3
No new posts Using API Gateway from CICS program CICS 0
No new posts Error to read log with rexx CLIST & REXX 11
No new posts COBOL -Linkage Section-Case Sensitive COBOL Programming 1
No new posts COBOL ZOS Web Enablement Toolkit HTTP... COBOL Programming 0
Search our Forums:

Back to Top