Answer Posted / glibwaresoftsolutions
A trigger is a block of PL/SQL code automatically executed in response to certain events (e.g., INSERT, UPDATE, DELETE) on a table.
Example Trigger:
CREATE OR REPLACE TRIGGER EmployeeAudit
AFTER INSERT ON employees
FOR EACH ROW
BEGIN
INSERT INTO audit_log(employee_id, action, action_date)
VALUES (:NEW.id, 'INSERT', SYSDATE);
END;
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Is primary key clustered index?
Which is better varchar or nvarchar?
How many row comparison operators are used while working with a subquery?
What is sqlerrm?
Is sql better than access?
What is trigger types of trigger?
why does the selected column have to be in the group by clause or part of an aggregate function? : Sql dba
How does one use sql*loader to load images, sound clips and documents? : aql loader
What is the size of partition table?
Does truncate release storage space?
What is a sql select statement?
Why are sql stored procedures used?
table structure: ---------------- col1 col2 ----- ----- 01-mar-2012 11:12:46 01-mar-2012 11:12:10 01-mar-2012 11:12:46 01-mar-2012 11:11:23 Write a query to display the result as shown below: col1 col2 ----- ----- 01-mar-2012 11:12:46 01-mar-2012 11:12:10
Why we use stored procedure instead of query?
How to read/write files from pl/sql?