Re: Diffence between two CICS READ ; FILE & DATASET



In article <1122442700.675092.150020@xxxxxxxxxxxxxxxxxxxxxxxxxxxx>,
"Praveen" <praveen.unnithan@xxxxxxxxx> wrote:

> Hi,
>
> I am a newbie in CICS COBOL. I came across two possible syntax to read
> a file from a CICS program. The two syntax that I came across were
>
> EXEC CICS
> READ DATASET ('RASSPLSW')
> INTO (RASSPLSW-RECORD)
> RIDFLD (W-USERID)
> RESP (W-RESP)
> END-EXEC.
>
>
> EXEC CICS
> READ FILE('RASSPLSW')
> INTO(USRRECC)
> RIDFLD(CURRUSR)
> END-EXEC.
>
> The two syntax mainly differ only in the use of FILE || DATASET. I
> would like to know this diffence...
>
> Thanks alot for your valuable time.
>
> Regards,
> Praveen.


I would need to know your full details -- e.g. version of CICS/TS,
internal/external translator -- of your installation.

FILE and DATASET are synonyms. The big difference with your two
examples is the automatic error handling of the second version, verses
the manual error handling of the first version.

If you specify the RESP keyword you must check it -­ it is the same as
if you specify the "NOHANDLE" keyword. Without it, CICS will trap many
abend conditions and end your task.

This works very similar to the Cobol "File-Status" keyword.
.



Relevant Pages

  • Re: Diffence between two CICS READ ; FILE & DATASET
    ... I am a newbie in CICS COBOL. ... I came across two possible syntax to read ... At some point in the past IBM changed the syntax of EXEC CICS READ and recommended using FILE for all future READ commands, but they still had to support the DATASET keyword in order to allow older CICS programs to compile and execute without any source code changes. ...
    (comp.lang.cobol)
  • Re: Diffence between two CICS READ ; FILE & DATASET
    ... zum Thema Diffence between two CICS READ; ... I came across two possible syntax to read ... and the other takes the fields USRRECC and CURRUSR. ...
    (comp.lang.cobol)
  • Diffence between two CICS READ ; FILE & DATASET
    ... I am a newbie in CICS COBOL. ... I came across two possible syntax to read ... a file from a CICS program. ... EXEC CICS ...
    (comp.lang.cobol)
  • Re: IBM, CICS, COBOL, et al
    ... > Old applications that do NOT use syntax that is no longer supported, ... > certainly be recompiled and run under the new CICS TS. ... Pete. ...
    (comp.lang.cobol)
  • Re: Looking for consult help getting to 31-bit CICS Cobol
    ... Looking for consult help getting to 31-bit CICS Cobol ... VSCobol. ... For IBM-MAIN subscribe / signoff / archive access instructions, ...
    (bit.listserv.ibm-main)