oracle_ORA-600[HO define: Long fetch] fetch data from sqlserv
(2013-05-27 09:49:26)
标签:
oracle600it |
分类: oraerror |
Applies to:
Oracle Database Gateway for SQL Server - Version 11.1.0.6 to 11.2.0.1 [Release 11.1 to 11.2]Information in this document applies to any platform.
Symptoms
The following error message is received when making a select using
an Oracle Database Gateway (such as Dg4ODBC, DG4MSQL) with third
party tools such as PL/SQL Developer or Toad for
Oracle
ORA-00600. Internal Error Code, Arguments: [HO define: Long fetch], [], [], [], [], [], [], []
The problem can also happen when using Oracle software.
Cause
The ORA-600 can happen for several reasons, the root cause of the
error with the third party applications depends on the table being
selected.
1. The table description contains 2 long or long raw columns , for
example -
MEMO
In Oracle there are limitations with LONG columns:
A table can contain only one LONG
column.
oracle表中只允许有一个LONG列字段。可以用函数进行截取。
See
Solution
The root cause of the ORA-600 error with the third party
applications depends on the table being selected and certain
applications will cause an ORA-600.
The workround is -
1. Create a view on the SQL Server or Oracle side avoiding a select
of more than one long/long raw column at the same time.
2. Specify the select list
3. Create a view on the non-Oracle database that truncates columns
to 4000 characters or less.
For example on SQL*Server -
( ID,
LogTime,
Action,
InstID,
Username,
Error,
SUBSTRING (Parm1,1 ,4000) as Parm1_4000 ,
SUBSTRING (Parm1,4001,8000)as Parm1_8000,
SUBSTRING (Parm1,8001,12000) as Parm1_12000,
SUBSTRING (Parm1,12001,16000) as Parm1_16000,
Cert
FROM view_log;
4. Use a view on SQL Server to cast the var(max) columns to another data type.
5. Use Oracle tools instead of third-party tools.