My Oracle Support Banner

ORA-28500 Or ORA-972 When a Non-Oracle Database Column Name Has More Than 30 Characters (Doc ID 1433102.1)

Last updated on JUNE 01, 2023

Applies to:

Oracle Database - Enterprise Edition - Version 11.2.0.1 to 11.2.0.3 [Release 11.2]
Oracle Database Gateway for SQL Server - Version 11.2.0.1 to 11.2.0.3 [Release 11.2]
Oracle Database Gateway for Sybase - Version 11.2.0.1 to 11.2.0.3 [Release 11.2]
Oracle Database Gateway for Informix - Version 11.2.0.1 to 11.2.0.3 [Release 11.2]
Oracle Database Gateway for Teradata - Version 11.2.0.1 to 11.2.0.3 [Release 11.2]
Information in this document applies to any platform.

Symptoms

You have a remote table with column name with more than 30 characters.
 Name                                      Null?    Type
 ----------------------------------------- -------- ----------------------------
 TESTING_THIRTY_CHARACTERS_DG4GTW                     CHAR(10)

When selecting data from a remote table having more than 30 characters in the column name using a Database Gateway, the following error is given:
(in this example, remote table is from SQL SERVER)

SQL> select * from "table_with_long_column"@dg112msql;
select * from "table_with_long_column"@dg112msql
*
ERROR at line 1:
ORA-28500: connection from ORACLE to a non-Oracle system returned this message:
[Oracle][ODBC SQL Server Native Wire Protocol driver][Microsoft SQL
Server]Invalid column name 'TESTING_THIRTY_CHARACTERS_DG4G'. {42S22,NativeErr =
207}[Oracle][ODBC SQL Server Native Wire Protocol driver][Microsoft SQL
Server]Statement(s) could not be prepared. {HY000,NativeErr = 8180}
ORA-02063: preceding 2 lines from DG112MSQL

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
Symptoms
Cause
Solution
References


My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.