10046解决PLSQL访问数据字典 显示授权问题
2014-11-20 16:49
435 查看
SQL> create or replace procedure test_trc IS msql varchar2(200); begin msql := 'insert into t100 select * from dba_objects'; execute immediate msql; commit; end; 2 3 4 5 6 7 8 / Procedure created. SQL> show err No errors. SQL> exec test_trc BEGIN test_trc; END; * ERROR at line 1: ORA-00942: table or view does not exist ORA-06512: at "TEST.TEST_TRC", line 5 ORA-06512: at line 1 SQL> ALTER SESSION SET EVENTS '10046 trace name context forever,level 12'; 执行过程居然报: SQL> exec test_trc; BEGIN test_trc; END; * ERROR at line 1: ORA-00942: table or view does not exist ORA-06512: at "TEST.TEST_TRC", line 5 ORA-06512: at line 1 SQL> ALTER SESSION SET EVENTS '10046 trace name context off'; Session altered /oracle/app10g/admin/orcl/udump/orcl_ora_9165.trc Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options ORACLE_HOME = /oracle/app10g/product/10.2.0/db System name: Linux Node name: jhoa Release: 2.6.18-194.el5 Version: #1 SMP Tue Mar 16 21:52:39 EDT 2010 Machine: x86_64 Instance name: orcl Redo thread mounted by this instance: 1 Oracle process number: 15 Unix process pid: 9165, image: oracle@jhoa (TNS V1-V3) *** ACTION NAME:() 2014-11-20 16:20:22.316 *** MODULE NAME:(SQL*Plus) 2014-11-20 16:20:22.316 *** SERVICE NAME:(SYS$USERS) 2014-11-20 16:20:22.316 *** SESSION ID:(1636.47) 2014-11-20 16:20:22.316 WAIT #2: nam='SQL*Net message to client' ela= 1 driver id=1650815232 #bytes=1 p3=0 obj#=-1 tim=1383273068668059 WAIT #2: nam='SQL*Net message from client' ela= 5733215 driver id=1650815232 #bytes=1 p3=0 obj#=-1 tim=1383273074401482 ===================== PARSING IN CURSOR #1 len=22 dep=0 uid=90 oct=47 lid=90 tim=1383273074401646 hv=769690522 ad='80ed20c8' BEGIN test_trc; END; END OF STMT PARSE #1:c=0,e=64,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=1,tim=1383273074401642 BINDS #1: ===================== PARSING IN CURSOR #3 len=37 dep=2 uid=0 oct=3 lid=0 tim=1383273074402315 hv=1398610540 ad='c0e8a398' select text from view$ where rowid=:1 END OF STMT PARSE #3:c=0,e=63,p=0,cr=0,cu=0,mis=0,r=0,dep=2,og=4,tim=1383273074402312 BINDS #3: kkscoacd Bind#0 oacdty=11 mxl=16(16) mxlc=00 mal=00 scl=00 pre=00 oacflg=18 fl2=0001 frm=00 csi=00 siz=16 off=0 kxsbbbfp=2b0a1692b280 bln=16 avl=16 flg=05 value=000018E0.0000.0001 EXEC #3:c=0,e=87,p=0,cr=0,cu=0,mis=0,r=0,dep=2,og=4,tim=1383273074402485 FETCH #3:c=0,e=40,p=0,cr=2,cu=0,mis=0,r=1,dep=2,og=4,tim=1383273074402545 STAT #3 id=1 cnt=1 pid=0 pos=1 obj=63 op='TABLE ACCESS BY USER ROWID VIEW$ (cr=1 pr=0 pw=0 time=29 us)' ===================== PARSE ERROR #2:len=42 dep=1 uid=90 oct=2 lid=90 tim=1383273074404068 err=942 insert into t100 select * from dba_object EXEC #1:c=3000,e=2549,p=0,cr=2,cu=0,mis=0,r=0,dep=0,og=1,tim=1383273074404245 ERROR #1:err=942 tim=446336866 WAIT #1: nam='SQL*Net break/reset to client' ela= 15 driver id=1650815232 break?=1 p3=0 obj#=-1 tim=1383273074404304 WAIT #1: nam='SQL*Net break/reset to client' ela= 52 driver id=1650815232 break?=0 p3=0 obj#=-1 tim=1383273074404372 WAIT #1: nam='SQL*Net message to client' ela= 0 driver id=1650815232 #bytes=1 p3=0 obj#=-1 tim=1383273074404395 *** 2014-11-20 16:20:35.053 WAIT #1: nam='SQL*Net message from client' ela= 6702657 driver id=1650815232 #bytes=1 p3=0 obj#=-1 tim=1383273081107101 ===================== PARSING IN CURSOR #3 len=55 dep=0 uid=90 oct=42 lid=90 tim=1383273081107348 hv=2655499671 ad='0' ALTER SESSION SET EVENTS '10046 trace name context off' END OF STMT PARSE #3:c=0,e=111,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=0,tim=1383273081107345 EXEC #3:c=1000,e=53,p=0,cr=0,cu=0,mis=0,r=0,dep=0,og=0,tim=1383273081107446 PARSE ERROR #2:len=42 dep=1 uid=90 oct=2 lid=90 tim=1383273074404068 err=942 insert into t100 select * from dba_object EXEC #1:c=3000,e=2549,p=0,cr=2,cu=0,mis=0,r=0,dep=0,og=1,tim=1383273074404245 解析的时候居然是被当成:insert into t100 select * from dba_object 在过程里访问数据字典,需要显示的grant select any dictionary to test;
相关文章推荐
- oauth 授权显示无权访问页面问题的解决方法
- 如何解决从mysql中读取数据时显示为乱吗的问题.
- 解决调用sql数据,显示英文时撑破tb的问题
- XP下如何解决“ASP.NET 未被授权访问所请求的资源”的问题
- datagridview中显示的数据导出到Excel——用最简单的方法解决科学计数法的问题
- 解决Oracle LogMiner获取数据字典文件需要修改UTL_FILE_DIR的问题
- 解决windows的数据访问保护(DEP)导致windows installer不能工作的问题
- Asp : 生成xml数据 及解决Flex里的中文显示乱码问题。。。
- Win7 访问网络共享文件夹显示空白目录的问题解决
- 智能设备下,在ComboBox控件添加了多项数据,只显示第一项数据,而不显示其它数据的问题解决办法
- 【转】TB(TerraBuilder)转换日志:解决影像数据坐标转换后,在Skyline平台不能显示的问题
- 解决FireFox访问Google Analytics不能正常显示Flash的问题
- 解决按钮重复提交问题 (Jtable中重复显示数据)
- 显示数据(从数据库中得到)中的html标签 用于解决数据在前台显示,样式被数据破坏的问题!!css
- ASP.NET 未被授权访问所带来的问题的解决方法。
- 文档库创建的子文件夹的URL显示为 http://[机器名]/.... 导致无法正常访问的问题解决办法
- 解决windows的数据访问保护(DEP)导致windows installer不能工作的问题
- SVN+Apache在windows下http访问 显示中文乱码问题的解决方法
- 解决Pro*C程序数据显示中出现在乱码问题。
- 使用Jsonp解决跨域数据访问问题[转]