Easy Learning... (Web Development,.NET Technology,Oracle,Silverlight,REST,SQL,Oracle,MySQL,Data Science, Python and many more ...)
Tuesday, October 13, 2020
RDBMS PLSQL Program 47 program to generate before insert,update and delete row trigger on emp table which will not allow changes in data on weekends using RAISE_APPLICATION_ERROR() function
CREATE OR REPLACE TRIGGER Weekend
BEFORE INSERT OR UPDATE OR DELETE ON emp
for each row
WHEN (TO_CHAR(SYSDATE,'day') IN('SATURDAY','SUNDAY'))
DECLARE
BEGIN
RAISE_APPLICATION_ERROR(-20001,'Enjoy your Weekend!! Do not do work!');
END;
/
No comments:
Post a Comment
Thanks for showing your interest I will shortly get back to you
No comments:
Post a Comment
Thanks for showing your interest
I will shortly get back to you