× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



cobol400-l-request@xxxxxxxxxxxx wrote:

>   6.  Convert into source  (Riyadi, Agus)
>
>In AS/400 we can retrieve CL object into it's source using RTVCLSRC command.


Agus:

This is both true and false depending on the initial conditions. You can 
retrieve CL source with RTVCLSRC if (1) the source was included with the 
compiled program and (2) it is not ILE CL. Possibly other conditions can be 
listed.

If you are using ILE, then "programs" aren't really COBOL nor CL nor RPG, etc. 
ILE "programs" are mostly sets of modules that are linked together and the 
modules may be any appropriate language. With that in mind, you would begin 
thinking about retrieving source from a COBOL "module" rather than a COBOL 
"program".

With OPM CL, you chose whether or not to allow source to be retrieved by 
specifying CRTCLPGM ALWRTVSRC(*YES). If the program was compiled with 
ALWRTVSRC(*NO), then RTVCLSRC won't work.

ALWRTVSRC(*YES) was probably the default at most sites. This made it handy.


>Any tools for retrieve Cobol program into it's source ?


Under ILE, a common way to include source in modules is to compile then with 
debug information. Similar to ALWRTVSRC(*YES), you could specify CRTCBLMOD 
DBGVIEW(*ALL) or DBGVIEW(*LIST). The source could then be recreated from the 
debug information in the module and the module would be part of a program.

I think DBGVIEW(*STMT) is the standard default. But *STMT doesn't provide much 
help with recovering source. Perhaps changing the command default is something 
to consider.

If you don't do something to include the source, then the source won't be 
available.

The expensive alternative would be a form of de-compile. AFAIK, this was 
essentially what source-retrieval companies had done in the past. I'm not sure 
if any have survived into the ILE era.

Tom Liotta


As an Amazon Associate we earn from qualifying purchases.

This thread ...


Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.