ORA-30951 from dbms_xmlschema.registerSchema (Doc ID 1374471.1)

Last updated on NOVEMBER 13, 2011

Applies to:

Oracle Server - Enterprise Edition - Version: 10.1.0.2 to 11.2.0.3 - Release: 10.1 to 11.2
Information in this document applies to any platform.

Symptoms

Registering an XML schema fails with errors:

SQL> begin
  2 dbms_xmlschema.registerSchema
  3 (
  4 schemaURL => '&1',
  5 schemaDoc => getDocument('&1'),
  6 local => TRUE,
  7 genTypes => &2,
  8 genBean => FALSE,
  9 genTables => &3,
 10 force => FALSE
 11 );
 12 end;
 13 /
old 4: schemaURL => '&1',
new 4: schemaURL => 'MyXSD.xsd',
old 5: schemaDoc => getDocument('&1'),
new 5: schemaDoc => getDocument('MyXSD.xsd'),
old 7: genTypes => &2,
new 7: genTypes => TRUE,
old 9: genTables => &3,
new 9: genTables => TRUE,
begin
*
ERROR at line 1:
ORA-30951: Element or attribute at Xpath
/schema/element[1]/complexType/sequence/element[2]/complexType/sequence/element[2]/annotation/appinfo[1][@] exceeds maximum length
ORA-06512: at "XDB.DBMS_XMLSCHEMA_INT", line 20
ORA-06512: at "XDB.DBMS_XMLSCHEMA", line 31
ORA-06512: at line 2

The XML schema has a large has large xsd:annotation (> 4K).

Cause

Sign In with your My Oracle Support account

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

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms