Home » Developer & Programmer » JDeveloper, Java & XML » Too long coloum name or elis error (10.2.0.4 windows xp)
Too long coloum name or elis error [message #421215] Sun, 06 September 2009 00:02 Go to next message
halim
Messages: 100
Registered: September 2008
Senior Member

Dears


My Query is :-

SELECT DBMS_XMLQUERY.getxml
          ('select deptno DepartmentId,dname DepartmentName ,loc LocationOfSpecifiedNecessaryDepartment from scott.dept'
          )
  FROM DUAL
  
  
output:
  
  <?xml version = '1.0'?>
<ERROR>oracle.xml.sql.OracleXMLSQLException: ORA-00972: identifier is too long
</ERROR>


This error is for too long (above 30 character) alis of loc
column.
but i need this type of long alis or (anything like this) for the requierment of XML tag generation.

How can i solve this problem plz...?
Re: Too long coloum name or elis error [message #421220 is a reply to message #421215] Sun, 06 September 2009 01:11 Go to previous messageGo to next message
Michel Cadot
Messages: 63802
Registered: March 2007
Location: Nanterre, France, http://...
Senior Member
Account Moderator
User replace.
SQL> SELECT DBMS_XMLQUERY.getxml
  2            ('select deptno DepartmentId,
  3                     dname DepartmentName,
  4                     loc LocationOfSpecifiedNecessaryDepartment 
  5              from scott.dept') res
  6  FROM DUAL
  7  /
RES
-----------------------------------------------------------------------------------------------
<?xml version = '1.0'?>
<ERROR>oracle.xml.sql.OracleXMLSQLException: ORA-00972: identifier is too long
</ERROR>

1 row selected.

SQL> SELECT replace(
  2         DBMS_XMLQUERY.getxml
  3     ('select deptno DepartmentId,
  4              dname DepartmentName,
  5              loc Location
  6       from scott.dept'),
  7     'LOCATION','LOCATIONOFSPEFICIEDNECESSARYDEPARTMENT') res
  8  FROM DUAL
  9  /
RES
-----------------------------------------------------------------------------------------------
<?xml version = '1.0'?>
<ROWSET>
   <ROW num="1">
      <DEPARTMENTID>10</DEPARTMENTID>
      <DEPARTMENTNAME>ACCOUNTING</DEPARTMENTNAME>
      <LOCATIONOFSPEFICIEDNECESSARYDEPARTMENT>NEW YORK</LOCATIONOFSPEFICIEDNECESSARYDEPARTMENT>
   </ROW>
   <ROW num="2">
      <DEPARTMENTID>20</DEPARTMENTID>
      <DEPARTMENTNAME>RESEARCH</DEPARTMENTNAME>
      <LOCATIONOFSPEFICIEDNECESSARYDEPARTMENT>DALLAS</LOCATIONOFSPEFICIEDNECESSARYDEPARTMENT>
   </ROW>
   <ROW num="3">
      <DEPARTMENTID>30</DEPARTMENTID>
      <DEPARTMENTNAME>SALES</DEPARTMENTNAME>
      <LOCATIONOFSPEFICIEDNECESSARYDEPARTMENT>CHICAGO</LOCATIONOFSPEFICIEDNECESSARYDEPARTMENT>
   </ROW>
   <ROW num="4">
      <DEPARTMENTID>40</DEPARTMENTID>
      <DEPARTMENTNAME>OPERATIONS</DEPARTMENTNAME>
      <LOCATIONOFSPEFICIEDNECESSARYDEPARTMENT>BOSTON</LOCATIONOFSPEFICIEDNECESSARYDEPARTMENT>
   </ROW>
</ROWSET>

1 row selected.


Regards
Michel
Re: Too long coloum name or elis error [message #421221 is a reply to message #421220] Sun, 06 September 2009 02:31 Go to previous message
halim
Messages: 100
Registered: September 2008
Senior Member

Dear Micheal
Again Many Many.... thanks

Best Regards
Halim
Previous Topic: Java stored procedure error compilation
Next Topic: XML in database - what are is your experience?
Goto Forum:
  


Current Time: Mon Sep 26 02:34:40 CDT 2016

Total time taken to generate the page: 0.10585 seconds