Preparing legacy programs for conversion



The following is a summary of known issues that may need to be addressed manually when converting RPG applications programs to RPG Open Access and Profound UI.

  • RPG III programs have to be converted to RPG IV. Ā This can be done using the CVTRPGSRC command.

  • Progams must be compiled with DFTACTGRP(*NO). Ā This can be specified on the compile command or added as an H spec option to the top of the program.

  • If you are using the Jobā€™s Start User Id to identify users, this will have to be changed toĀ use the Jobā€™s Current User Id, as the Jobā€™ Start User Id does not contain the expectedĀ data in a browser environment, unless you are calling the converted program from Genie.

    • Ā SDS positions 254-263 will give you the wrong user profile in a web environment. What youā€™ll want to use is positions 358-367. This is the ā€œcurrent user profileā€ of the job which will give you who signed in.

    • Ā If using the RTVJOBA command, try using the CURUSER parameter instead of the USER parameter. This will make it work properly for you.

  • When running programs within the HTTP subsystem, generated spooled files areĀ assigned to a separate job named QPRTJOB. This will require modifying certain logic that depends onĀ OVRPRTF or CPYSPLF commands.Ā  SeeĀ IBM Info Center for more information. If you are calling the converted program from Genie, this is not a problem.

  • Data structures based on display file record formats will not have the same layout as inĀ the original application. Programs that use such data structures would have to beĀ modified.

  • In converted programs, certain INFDS (Information Data Structure) fields may not beĀ available or will provide different information compared to the green-screen environment.Ā These programs will have to be modified.

  • Use of special values, such as *DATE to retrieve the current date may not work asĀ expected. *DATE represents the job start date. Ā In a Web environment, this will return the date the HTTP server job started, which may or may not be the same as the date the session started. Ā However, if you are calling the converted program from Genie, this should not be an issue.