运行存储过程的用户需要有create any view
select any table的权限

解决方案 »

  1.   

    只是执行存储过程时会报错,在SQLPLUS中直接创建或者用
    begin
    execute immediate 'create or replace view aa_v as select * from pub_goods';
    end;
    都是可以的
    为什么只在存储过程里就权限不足了?
      

  2.   

    你是不是用同一个用户连的啊?再说,直接写成
    begin
     create or replace view aa_v as select * from pub_goods;
    end;
    不好吗?