Re: Using variable in trigger - high CPU usage problem
I finally opted for setting an event executed each day which updates a MEMORY table so I can in the trigger do:
DECLARE value INT;
SELECT `id` INTO value FROM mem_table WHERE `name`='Something';
IF (new.id=value) THEN
INSERT INTO `accu_table` (id, ...columns...) VALUES(N, ...columns...);
END IF;
This does not influence CPU measurably.
Subject
Views
Written By
Posted
3323
June 28, 2012 03:35AM
Re: Using variable in trigger - high CPU usage problem
1917
June 29, 2012 02:12AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.