易截截图软件、单文件、免安装、纯绿色、仅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的索引和约束详解

 * 如果某个约束只作用于单独的字段,即可以在字段级定义约束,也可以在表级定义约束,但如果某个约束作用于多个字段, 
必须在表级定义约束 
* 在定义约束时可以通过CONSTRAINT关键字为约束命名,如果没有指定,ORACLE将自动为约束建立默认的名称 
定义primary key约束(单个字段) 
create t ......

oracle decode使用方法

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

ORACLE常用数值函数、转换函数、字符串函数介绍

 
    本文并不准备介绍全部的oracle函数,当前情势下,俺也还没这个时间,需要学习的东西太多了,要把多数时间花在学习经常能用上的技术方面:),所以如果是准备深入了解所有oracle函数的朋友,还是去关注:Oracle SQL Reference官方文档更靠谱一些。
  本文更多将会介绍三思在日常中经常会用到的 ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号