Is there a possibility of scanning NATURAL code for strings with the use of REXX language in IBM Mainframe. Many thanks in advance. Any Suggestion in this regard helps me a lot.
If you have access, why not use SCAN inside Natural.
If you have no access to SCAN, and you are able to unload / write objects (using SYSBOJH or other utilities) to datasets, the SuperC search facility of TSO (3.14) should be good enough. Works best if you unloaded to a PDS / PDSE. If sequential, you’ll just have to see the object name where you found it.
I have a list of programs in which i have to search for an occurance of a string. In JGUSCAN it is infered that the string search is restricted to either the whole library or a single program. My requirement is to string search only for some NAT modules belonging to a library. I thought REXX would help me in this case. I’m afraid whether i am articulate in my requirement. please let me know.
Is REXX a prerequisite?
If not I recommend to use Natural SCAN command. It offers the functionality to scan/replace for text in Natural sources. It is possible to restrict the scanned sources by library, name and type.
The SCAN can be performed online, in Batch or via SPoD.
REXX is not my prerequisite. I tried using SCAN in online mode, it is working fine. Can you explain me the BATCH part of it. Do BATCH mode means calling a NAT module with the SCAN command in it through a JCL. If it so, i am unable to stow the module with SCAN command in it. Please correct me if i had got the concept wrong.
SCAN is a Natural command, so you can do it online or batch. In batch, you enter SCAN and the parameters you need. Please consult the documentation for the syntax. Since SCAN and STOW or CATALOG are all Natural commands, they can be restricted by your administrator. Consult your administrator if you can be granted access to these commands if you really require these functions.