码迷,mamicode.com
首页 > 数据库 > 详细

when will a databasechange be committed?

时间:2015-03-30 20:26:01      阅读:171      评论:0      收藏:0      [点我收藏+]

标签:

1) Database-updates via DML in a SQLExec-statement (e.g. INSERT INTO PS_TEST_TABLE VALUES(‘value_field_1′,’value_field_2′), triggered via an online component:
Peoplebooks states that DML in a SQLExec-statement is only allowed in FieldChange, SavePreChange, Workflow and SavePostChange events.
There’s a big difference in the outcome per event though; when this statement is put in a FieldChange-event, the DML is committed instantly, and this is something you probably don’t want!

2) Database-updates via DML in a SQLExec-statement (e.g. INSERT INTO PS_TEST_TABLE VALUES(‘value_field_1′,’value_field_2′), triggered via an Application Engine:
These updates are being committed according the AppEngine’s commit-settings.

2) Database-updates via a component interface, triggered via an online component (e.g. component A triggers component interface B_CI, triggering component B):
These updates are being committed as soon as the CI save-method is being invoked from the calling component (e.g. component A).

3) Database-updates via a component interface, triggered via an Application Engine (eg. AppEngine AE_1 triggers component interface B_CI, triggering component B):
These updates are being committed according the AppEngine’s commit-settings.
An exception to this rule I just recently encountered: the GetFile-statement leads to an immediate commit, even when used in an AppEngine-context!

在PLSQL中操作record时,有必要Commit的要手动处理,有时可能会发生锁表。

when will a databasechange be committed?

标签:

原文地址:http://www.cnblogs.com/binquan/p/4378848.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!