While developing in forms, we run into the following two scenarios very often

1.Select values into a database field from a post query trigger.

2.Do a direct update, delete from a trigger i.e. instead of deleting or updating records from Forms, we directly do the said DML operation using UPDATE or DELETE statements.

 

In the first case, forms assume that the database field has changed, and will prompt you to save the record.

In the second case, forms has no knowledge of the update or delete, as it did not happen via a forms block, as such when the transaction is saved, the user will not get the customary “ Transaction complete. 1 record saved” message. Instead one will see the message “ No changes to save”.

 

The following two solutions work in avoiding the prompt to save the record, display appropriate message on an update or delete respectively. They are

 

1.

SET_RECORD_PROPERTY (:SYSTEM.TRIGGER_RECORD,’ BLOCK NAME’,STATUS, QUERY_STATUS );

 

2.

SET_RECORD_PROPERTY (:SYSTEM.TRIGGER_RECORD, ‘BLOCK NAME’,STATUS, CHANGED_STATUS );

Hosted by www.Geocities.ws

1