Page 1 of 1

Using OCOPY in REXX gives return code -2.

Posted: Tue Nov 24, 2015 10:59 am
by durga
I'm trying to copy a load module from one library to another. For this I am using OCOPY in REXX. But OCOPY gives a return code -2. Code is something like this:

Code: Select all

   "ALLOC F(IN) DS('ORIGINAL.LOAD.PDS(MEMBER)') SHR" 
   "ALLOC F(OUT) DS('NEW.LOAD.PDS(MEMBER)') SHR" 
   "OCOPY INDD(IN) OUTDD(OUT) BINARY" 
Because I get a negative return code. I thought it can be an environmental error, but I can't find an explanation of -2 anywhere. Any pointers on what might be going on will be very helpful?

Thanks.