Do you need to recompile LANSA for iSeries programs when field level validation has changed?

Date:14 February 2005
Product/Release:LANSA for iSeries
Abstract:When do LANSA for iSeries programs need to be recompiled.
Submitted By:LANSA Services
Last Review:November 2010

Question:

We use LANSA for iSeries and we changed a LANSA file definition to add certain field level validations. The file was compiled to reflect the changes.

Is it necessary now to re compile all the programs that use this file since some field level rules on the file have change?

Answer:

When you make a file definition change in LANSA there is a series of considerations to cover.

Usually, only the OAM need be recompiled, which happens automatically as part of making the file operational.

Before you start, take the option (Option 6 in the 5250 interface) to print the file definition. It will indicate which of the following steps are required, by listing which objects, if any, should be recompiled:

  1. recompile trigger functions
  2. recompile functions with *DBOPTIMIZE / SQL
  3. recompile other OAMs (files) which use the changed file in file-lookup rules
  4. recompile functions which PASS_DS or RCV_DS for that file

It is rare that all of these steps are required, but that will depend on your use of *DBOPTIMIZE, passing data structures etc.

Review the table in the iSeries tip "When and what do I re-compile?" that lists what to re-compile depending on what changes have been made. The iSeries User Guide also has more details.

Knowing how to properly proliferate a database change is something that will serve you well in the future.