各位大神,关于触发器的,请教一个问题,有四张表A,B,C,D,四个表中都有一个字段X,想实现不管修改上述哪个表中的X值,其他三张表都自动触发更新,请问题有啥办法实现没?老是被锁住,感谢!
解决方案 »
- oracle中,拼出来的一个sql查询语句,怎么可以获得这个语句查询到的字段,及字段类型?
- oracle procedure的参数列表在那个动态性能视图里?
- 关于视图的一个小问题
- 在pl/sql developer里12位长度以上数字显示问题
- linux下如何在开启机器的时候自动启动数据库?
- 下面的SQL是什么意思??
- 提问:一个很简单的问题
- 两种连接,哪种更优?【查询的优化问题】
- ORACLE初学者,请问有什么好书介绍一下!
- oracle form builder 和oracle weblogic server 之间有什么联系吗?
- [请教]关于oracle的NLS运作问题
- 求助:两个 t-sql转plsql语句
before insert or delete or update on table_a
for each row
begin
if inserting then
insert tableB ( x) values(:new.X);
insert tableC (x) values(:new.X);
...
end if ;
if updating then
update tableB set x = :new.X where x =:OLD.x;
update tabelC set x =:new.X where x =OLD.X;
..
end if ;
if deleting then
delete from tableB where x=:old.x;
delete from TableC where x =:old.x;
..
end if
end tri_iud;
/
select * from A where id=1 for update nowait;然后增加异常处理模块,如果遇到update冲突异常直接回滚。