Based on the first migration of this function, if the record is
available, the migration tool creates the corresponding EGL statement(s) based
on the record type.
For SQL, the migration tool does the following:
- Always includes a resultSetID when migrating any UPDATE or SETUPD
function. The resultSetID is created using the function name and a
user-specified suffix.
- Includes the resultSetID when migrating any REPLACE function that
specified a corresponding UPDATE or SETUPD function name. The
resultSeID is created using the corresponding UPDATE or SETUPD function name
and a user-specified suffix.
For non-SQL, the migration tool always omits the resultSetID when migrating
an UPDATE function. There are no SETUPD functions for non-SQL
I/O.
| When migrating an UPDATE function, if the record is not available, the
migration tool does the following:
- Attempts to determine if this function is for SQL I/O by checking if the
function also has SQL clauses or any SQL-specific information such as
Execution Time Statement Build, single row select, or cursor with hold.
- If the migration tool can determine that this UPDATE statement is for an
SQL record, the migration tool includes the resultSetID in the get
statement.
- Otherwise, the migration tool does not include the resultSetID. The
migration tool issues a warning message.
When migrating a SETUPD function, the migration tool always includes the
resultSetID because SETUPD is only valid for SQL.
When migrating a REPLACE function, the migration tool includes the
resultSetID if the function specifies a corresponding UPDATE or SETUPD
function name.
|
Potential Problem: None.
|
Potential Problem: A problem only arises if an unmodified
UPDATE function really does refer to an SQL record and is used in a program
where there are multiple get or open for update
statements. In this case, each replace statement will
include a resultSetID, but the get statement that was migrated for
the VAGen UPDATE statement will not include the resultSetID.
Preprocessing for the program will fail.
Solution: Modify the function to include the resultSetID
for the get statement.
|