日期:2014-05-17  浏览次数:21175 次

oracle函数中能用update吗?
我写了一个oracle函数
比如 update_pw(uid)

其中有 update sys_user set pw = '130' where user_id = uid;
commit;

我在 pl/sql下测试时没有问题的

在web页面上调用不行 ,请教这是什么情况?

select update_pw('su') from dual;
------解决方案--------------------
可能web的驱动不支持,具体说下你的WEB怎么调用的,java 还是.net,用什么方式
------解决方案--------------------
建议楼主看看这个
http://blog.csdn.net/gigiouter/article/details/7616627
使用自治事务应该就可以了。