Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

DB2 Trigger creation setting in aqua studio

Status
Not open for further replies.

pkumarbi1

Programmer
Aug 15, 2018
1
US
I am trying a create Triggers from Aquastudio and ended up with below error.

CREATE TRIGGER VO.ADMIN_TOOL_T02
AFTER
DELETE
ON VO.ADMIN_TOOL
REFERENCING
OLD AS OLD
FOR EACH ROW
MODE DB2SQL
BEGIN ATOMIC
INSERT INTO VO.ADMIN_TOOL_AUD(
TOOL_URI_X,
MIGRATED_F,
STATUS_X,
UPDATED_LOGIN_NM,
LAST_USE_TS,
UPDATED_GUID_X,
UPDATED_TS,
ACTION_C)
VALUES(old.TOOL_URI_X,
old.MIGRATED_F,
old.STATUS_X,
old.UPDATED_LOGIN_NM,
old.LAST_USE_TS,
old.UPDATED_LOGIN_NM,
CURRENT TIMESTAMP,
'D');
END;

Error as below :

Describe Error: Failed to disable execution plan: "SYSTOOLS.EXPLAIN_OPERATOR" is an undefined name.. SQLCODE=-204, SQLSTATE=42704, DRIVER=3.67.28

[Error] Script lines: 1-10 ------------------------- An unexpected token "END-OF-STATEMENT" was found following "RENT TIMESTAMP, 'I')". Expected tokens may include: "".. SQLCODE=-104, SQLSTATE=42601, DRIVER=3.67.28

[Executed: 8/14/2018 6:25:14 AM] [Execution: 0ms]

[Error] Script lines: 11-12 ------------------------ An unexpected token "END-OF-STATEMENT" was found following "END ". Expected tokens may include: "JOIN ".. SQLCODE=-104, SQLSTATE=42601, DRIVER=3.67.28

[Executed: 8/14/2018 6:25:14 AM] [Execution: 0ms]

If I remove BEGIN ATOMIC , END then it is working. As per company standards I need to include them and make my aqua studio to work with those settings. Please advice.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top