Programming Guide



COPY_FOR_UPDATE

Changes the transaction manager to update mode

int sm_tm_command ("COPY_FOR_UPDATE");

Description

COPY_FOR_UPDATE changes the current mode to update. This allows the data currently displayed on the screen to be modified, as though it had been fetched from the database. After you select COPY_FOR_UPDATE, the transaction manager initializes before image processing.

If you edit the data and select SAVE, the transaction manager generates statements as if the data now on the screen had come from a SELECT command. If corresponding data is not in the database, the results might not be what you expect.

Push buttons and menu selections for the COPY_FOR_UPDATE command can choose to set the class property to continue_button since, by default, continue_button is active in view or update modes.

Sequence

COPY_FOR_UPDATE is available from any mode. Select SAVE after you finish your edits.

Events

The following requests can be generated by the COPY_FOR_UPDATE command to ascertain whether the changes from the previous command have been saved and, if desired, discard those changes: