Update Policy property

Official Content
This documentation is valid for:
Sets whether the Transaction will allow editing attribute values or not. Besides, if the Transaction has associated table(s), the "Read Only" value will not allow updating those tables through Procedures or other objects.


Read Only The Transaction will not allow editing attribute values. Besides, if the Transaction has associated table(s), you will not be able to update their attributes through procedures or any object.
Updatable The Transaction will allow editing the attribute values.


Objects: Transaction


This property applies only at design-time.


1) Consider the following Transaction object:


Suppose its Data Provider property = True and its Used to property = Populate data (the Data Provider's purpose is to populate). Thus, the Data Provider stores all the necessary data in the MaritalStatus physical table (as shown in the following image) and the objective is to keep those values unchanged: 


To this end, you have to set the Transaction Update Policy property to Read-Only. Thus, the attribute values will not be able to be updated by end users (because the Transaction form behavior will be read-only) nor by you through GeneXus objects.

2) Now, suppose a Country Transaction has its Data Provider property = True and its Used to property = Populate data, too. That Data Provider stores only some initial data in the Country physical table. So, it is reasonable to set the Update Policy property to Updatable, so that end users can add new countries and edit them.



3) See the following example that uses this property to implement Dynamic Transactions that update data.


4) Suppose a Transaction object with an associated Data View. If you want to be able to read the external table, but not to allow updating it (because it is done via API -referenced module or services-), you can set the Update Policy property to Read Only.


This property is available since GeneXus 15.