I was facing a problem while executing a small piece of code written in REXX on Mainframes which had file operation functions like LINES(),LINEIN() and CHAROUT()
HERE is the REXX CODE :
-------------------------------------------------
parse upper arg inpf
i=1
say i
say "dsname passed from jcl is:"
say inpf
Do while LINES(inpf)
st.i= LINEIN(inpf)
rc=CHAROUT(inpf," ",3)
if rc<> 0 then
say "Failed to replace characters"
i=i+1
End
say i-1 "lines were replaced with spaces"
exit
---------------------------------------------------
And, the JCL used to execute the REXX throws error ,
---------------------------------------------------
READY
CHREXX1 TP.ECRM.GDGDATE1
1
dsname passed from jcl is:
TP.ECRM.GDGDATE1
9 +++ Do while LINES(inpf) /**/
Error running CHREXX1, line 9: Routine not found
READY
END
----------------------------------------------------
I dont know why file functions are not recognised...
Please help !!!!
HERE is the REXX CODE :
-------------------------------------------------
parse upper arg inpf
i=1
say i
say "dsname passed from jcl is:"
say inpf
Do while LINES(inpf)
st.i= LINEIN(inpf)
rc=CHAROUT(inpf," ",3)
if rc<> 0 then
say "Failed to replace characters"
i=i+1
End
say i-1 "lines were replaced with spaces"
exit
---------------------------------------------------
And, the JCL used to execute the REXX throws error ,
---------------------------------------------------
READY
CHREXX1 TP.ECRM.GDGDATE1
1
dsname passed from jcl is:
TP.ECRM.GDGDATE1
9 +++ Do while LINES(inpf) /**/
Error running CHREXX1, line 9: Routine not found
READY
END
----------------------------------------------------
I dont know why file functions are not recognised...
Please help !!!!