dba_source :ORA-00942: table or view does not exist该包通过pl/sql developer可以看到
袄,你没有权限访问dba_source。用SYSDBA查查dba_source
请问怎么用SYSDBA查查dba_source?
你有SYS用户吗?简单点,以它登录数据库,查看dba_source
su - sys $ sqlplus /nologsu: sqlplus: not found.
[oracle@ehtdb1 /home/oracle]$whoami oracle [oracle@ehtdb1 /home/oracle]$sqlplus / as sysdbaSQL*Plus: Release 10.2.0.4.0 - Production on Fri Jan 8 13:40:27 2010Copyright (c) 1982, 2007, Oracle. All Rights Reserved. Connected to: Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing optionsSQL> select * from dba_source 2 where rownum<=10;OWNER NAME TYPE ------------------------------ ------------------------------ ------------
红色部分的值有没有大写?
还都是空
1 该包确实存在,但你无权访问。所以all_source里没有,试试dba_source。
2 该包不存在。
$ sqlplus /nologsu: sqlplus: not found.
oracle
[oracle@ehtdb1 /home/oracle]$sqlplus / as sysdbaSQL*Plus: Release 10.2.0.4.0 - Production on Fri Jan 8 13:40:27 2010Copyright (c) 1982, 2007, Oracle. All Rights Reserved.
Connected to:
Oracle Database 10g Enterprise Edition Release 10.2.0.4.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing optionsSQL> select * from dba_source
2 where rownum<=10;OWNER NAME TYPE
------------------------------ ------------------------------ ------------
如果有足够的权限,可以直接用dbms_metadata.get_ddl来查看