Try OpenEdge Now
skip to main content
Data Access and Business Entity Objects : Data Access object : Elements of a Data Access object : Specialized update API
Specialized update API
The ProDataSet update examples use a generic update procedure called commitChanges.p to return updates to the database. It illustrates how you can attach validation logic procedures in a standard way much as you would do for SmartDataObjects in the ADM2. In a large percentage of cases this can provide you with a general purpose update mechanism that applies to many different Business Entities.
There are however cases where a generic procedure will not be adequate. In particular, if there are no standard Data-Sources to attach to the ProDataSet, because the data source is unstructured data, then there can also be no built-in update support, and you will need to write your own update API to accept changed ProDataSets and do whatever is necessary to get those changes back to the data sources. As with the retrieval API, it is best if any requests from outside the Business Entity go through the Business Entity, which can then make the right request of the Data Access object to get the job done.