View previous topic :: View next topic |
Author |
Message |
karavi2000 Beginner
Joined: 17 Aug 2003 Posts: 51 Topics: 26 Location: Chennai
|
Posted: Fri Jan 30, 2004 7:06 am Post subject: Reg: Reading a PDS Member thru' REXX |
|
|
Hi,
When I was trying to Read a PDS member and put into stem variable, my "ALLOC DA('DSNM') F(INDD) SHR" abruptly fails with an RC of 28. I have my DSNM dataset cataloged. I am just giving the code which i used here. Please let me know what might be the problem.
IF SYSDSN(DSNM) = 'OK' THEN DO
"ALLOC DA("DSNM") F(INDD) SHR"
SAY "AFTER ALLOC STATEMENT: " RC /* Returns 28 after execution */
END
Thanks & Regards,
Ravishankar |
|
Back to top |
|
 |
superk Advanced

Joined: 19 Dec 2002 Posts: 684 Topics: 5
|
Posted: Fri Jan 30, 2004 8:12 am Post subject: |
|
|
I, for one, couldn't duplicate the error.
The exec code worked just fine, whether I allocated DSNM to a PDS, or to a PDS(MEMBER).
The only problem I saw was that, if DSNM was allocated to the entire PDS, without the addition of a "FREE" statement at the end, a subsequent run produced a RC=12 'DATASET IS IN USE'. |
|
Back to top |
|
 |
karavi2000 Beginner
Joined: 17 Aug 2003 Posts: 51 Topics: 26 Location: Chennai
|
Posted: Fri Jan 30, 2004 9:06 am Post subject: |
|
|
Hey,
The problem is since I was writing it as a macro, I didnt give "ADDRESS TSO" at the start. When I gave it just before the ALLOC statement, my code worked fine.
Hey Superk. Thanks for your response. Continue your good work.
Thanks & Regards,
Ravishankar |
|
Back to top |
|
 |
|
|