create table t1(id number primary key,name varchar2(100));
insert into t1 values(1,'aaa'); insert into t1 values(2,''bbb'); commit; create or replace function fun1(p_id number ) return varchar2 is Result varchar2 ( 100 ); begin select name || 'aa' into Result from t1 where id=p_id; return ( Result ); end fun1; update t1 set name =(fun1( 2 )) where 1 = 1 ; posted on 2012-05-05 07:34 蓝红石 阅读( ...) 评论( ...) 编辑 收藏转载于:https://www.cnblogs.com/liuweihua/archive/2012/05/05/2484443.html