标签:
在sys用户下执行:
CREATE OR REPLACE TRIGGER lms2014
BEFORE create or DROP OR ALTER ON database
DECLARE
BEGIN
IF ora_dict_obj_owner = ‘LMS2014‘ AND ora_sysevent = ‘DROP‘ THEN
raise_application_error(-20002,‘不允许删除对象,请联系产品经理‘);
ELSIF ora_dict_obj_owner = ‘LMS2014‘ AND ora_sysevent = ‘ALTER‘ THEN
RAISE_APPLICATION_ERROR(-20001,‘不允许修改对象结构,请联系产品经理‘);
ELSIF ora_dict_obj_owner = ‘LMS2014‘ AND ora_sysevent = ‘CREATE‘ THEN
RAISE_APPLICATION_ERROR(-20001,‘不允许创建对象结构,请联系产品经理‘);
END IF;
END;
标签:
原文地址:http://www.cnblogs.com/czrwxw/p/4250182.html