Kbase P86779: When doing a SAVE-ROW-CHANGES(), if a database trigger returns an error string how can that string b
Autor |
  Progress Software Corporation - Progress |
Acesso |
  Público |
Publicação |
  2/3/2009 |
|
Status: Verified
GOAL:
When doing a SAVE-ROW-CHANGES(), if a database trigger returns an error string how can that string be gathered and returned in the tables ERROR-STRING attribute?
FACT(s) (Environment):
All Supported Operating Systems
OpenEdge 10.x
FIX:
If a database trigger flags an error condition (and consequently the undo of the transaction) by using the RETURN ERROR "SomeString" statement the "SomeString" part of the RETURN ERROR statement can be captured as follows:
hBufferForTableInDataSet:SAVE-ROW-CHANGES() NO-ERROR.
IF RETURN-VALUE <> "" THEN
ASSIGN hBufferForTableInDataSet:ERROR-STRING = RETURN-VALUE.