易截截图软件、单文件、免安装、纯绿色、仅160KB

Oracle Compile 对象

 Applies to:
Oracle Server - Enterprise Edition - Version: 10.1.0.5.0
This problem can occur on any platform.
Symptoms:
The issue is that the following error was raised :
ORA-00600: internal error code, arguments: [kesutlGetBindValue-2], [], [], [], [], [], [], []
The recent changes was the :
Migration from 10.1.0.5.0 database control to Grid Control Agent v10.2.0.3.0
What was runing at this moment of the error occurance was :
The attempt to run SQL Tuning Advisor from Grid Control
Cause:
Possibly invalid objects in the database.
As the issue here was to try to use these packages and then failed:
SYS.DBMS_SQLTUNE_INTERNAL
body SYS.PRVT_ADVISOR
body SYS.DBMS_ADVISOR
body SYS.DBMS_SQLTUNE
And as mentioned with the recent changes was the migration.
Solution:
1. fixup
1). connect to the database as sysdba:
sqlplus "/ as sysdba"
2). shutdown immediate
3). startup migrate
4). @?/rdbms/admin/catalog.sql
5). @?/rdbms/admin/catproc.sql
6). @?/rdbms/admin/utlrp.sql
7). shutdown immediate
8). startup
SELECT UNIQUE OBJECT_TYPE from ALL_objects where status = 'INVALID';
select 'ALTER ' || OBJECT_TYPE || ' '||owner||'.' || OBJECT_NAME || ' COMPILE;'
from  all_objects where  status = 'INVALID'
and  object_type in ('PACKAGE','FUNCTION','PROCEDURE', 'TABLE', 'VIEW', 'SEQUENCE', 'TRIGGER');
  
    
   SELECT * from dba_users;
   select 'ALTER PACKAGE ' || OWNER||'.'|| OBJECT_NAME || ' COMPILE body;'
from ALL_objects where status = 'INVALID' and object_type in ('PACKAGE BODY');
SELECT UNIQUE OBJECT_TYPE from ALL_OBJECTS;
2. Verify that the status of the CATPROC :
SQL> col comp_id format a10
SQL> col comp_name format a30
SQL> col version format a10
SQL> select comp_id, comp_name, status, version from dba_registry;
and the status of the other objects:
SQL> col object_name format a30
SQL&g


相关文档:

oracle decode使用方法

数据库中经常用0,1 来标识某字段,作为开发人员可能知道它的意义,但我们让它显示在Grid列表上必须显示它的实际含义,一般我们可以在代码中读数据源时可以作处理,同时ORACLE中用decode也是不错方法。
   decode(条件,值1,翻译值1,值2,翻译值2,...值n,翻译值n,缺省值)
    该函数的含义如下:
......

oracle数据库里面commit关键字的使用

    在oracle数据库中插入数据时,运行插入语句,先是把数据放入到缓存中,这时数据并没有真正的进入数据库,这是oracle数据库跟其它数据库中的不同点,这是要运行commit这个事务提交,才能真正的把数据放到数据库中。 ......

Oracle 用户名详解

安装ORACLE时,若没有为下列用户重设密码,则其默认密码如下:
用户名/密码
登录身份
说明
sys/change_on_install
SYSDBA或SYSOPER
不能以NORMAL登录,可作为默认的系统管理员
system/manager
SYSDBA或NORMAL
不能以SYSOPER登录,可作为默认的系统管理员
sysman/oem_temp
 
sysman 为oms的用户名
scott/ ......

oracle中connect by prior实现递归查询

oracle中connect by prior实现递归查询
收集的几条在oracle中通过connect by prior来实现递归查询
Start with...Connect By子句递归查询一般用于一个表维护树形结构的应用。
创建示例表:
CREATE TABLE TBL_TEST
(
ID    NUMBER,
NAME VARCHAR2(100 BYTE),
PID   NUMBER    ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号