Joined: 30 Dec 2003 Posts: 1 Topics: 1 Location: India
Posted: Tue Dec 30, 2003 7:03 am Post subject: COBOL program to access dataset values
Hi,
I am developing a COBOL program to perform a search on a PDS. This is something that I cannot do using 3.14.
I was able to use LMINIT, LMOPEN, LMMLIST, LMFFIND etc calls to ISPF successfully.
But, I am unable to view the contents of the dataset thru LMGET. The return-code is 0 though. I am not aware of the method by which I could 'connect' the ISPF returned variables in the program to COBOL as it is done for any Assembler calls.
My code is:
MOVE 250 TO ISPF-BIG-BUFLEN.
MOVE SPACES TO ISPF-BIG-BUFLIST.
MOVE "LMGET DATAID(&MYPDS)" TO ISPF-BIG-BUF(1).
MOVE "MODE(INVAR)" TO ISPF-BIG-BUF(2).
MOVE "DATALOC(LOCVAR)" TO ISPF-BIG-BUF(3).
MOVE "DATALEN(LENVAR)" TO ISPF-BIG-BUF(4).
MOVE "MAXLEN(80)" TO ISPF-BIG-BUF(5).
CALL "ISPEXEC" USING ISPF-BIG-BUFLEN ISPF-BIG-BUFLIST.
When I display LOCVAR, LENVAR they are empty. So, I understand that there is some other way by which I am expected to read the contents of the dataset.
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum