From the help files I get this. Note the bolded phrase. The example specifically changes a value in the update statement. Are you being confused by the syntax where R:Base does not specifically include the keyword BEFORE in the before triggers?

Albert

***********************************
The SYS_NEW parameter is used in a WHERE <where.htm>clause within, and only within, the context of a Trigger <topic_triggers.htm>.

This virtual pointer is available to INSERT and UPDATE triggers. It allows code to access the contents of the row *as it will be after the INSERT or UPDATE*action. Using this in the body of a WHERE clause allows code to act on the contents of that virtual row and NOT fire off another trigger.

Example

The following command is within the body of an Insert Trigger and is being used to increment the count of how many items have been used.

SELECT ProductType INTO vPType INDIC v1 +

FROM SalesDetails +

WHERE CURRENT OF SYS_NEW

UPDATE ProductCount +

SET ProductCount = (ProductCount + 1) +

WHERE ProductType = .vPType

********************************************
On 2/28/2014 7:09 PM, James Bentley wrote:

Albert,

If as you sy we can alter the SYS_NEW record in an BEFORE INSERT or BEFORE UPDATE trigger I would appreciate your posting to this list. To the Best of knowledge the SYS_NEW record is implemented as a READ ONLY Cursor and
cannot be altered within the trigger code.

Jim Bentley,



American Celiac Society



1-504-737-3293


Reply via email to