unfortunately the code posted is severely flawed
IX is an index ( integer number )
ISFLINE.0 is an integer telling how many ISFLINEs are there
so why compare a <data line> with a number
anyway after the end of the loop IX will contain ISFLINE.0 + 1
and it should raise the NOVALUE condition ... ... ...
the count of the END statements dies not match the number of the DO statements ... ... ...
why use a recursive CALL ... ... ...
wiser to rethink the whole logic
after the SDSF read
Address TSO "EXECIO " isfline.0 " DISKW <ddname> ( STEM ISFLINE. FINIS
will write all the ISFLOG lines without the need for any loop
see here why using the * for the EXECIO write is a BAD PRACTICE
http://ibmmainframes.com/about60269.html
and frankly there are too many errors
describe and understand the logic before staring the coding