Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Float datatypes in Schema-constrained XMLType columns in Oracle 9iR2

Float datatypes in Schema-constrained XMLType columns in Oracle 9iR2

From: Ludovic Copéré <copere.ludovic_at_ec-lille.fr>
Date: Fri, 7 Mar 2003 15:09:33 +0100
Message-ID: <b4a999$veg$1@netserv.univ-lille1.fr>


Hello everyone,

I'm experiencing a very nasty problem while working with the XML functionalities of Oracle 9iR2. Indeed, I receive error ORA-31038 when I try to insert in my table a valid XML document containing floats.

With the following ( very simple) example, the error still occurs:

begin
dbms_xmlschema.registerSchema(
'http://www.ec-lille.fr/test1.xsd',
'<xs:schema xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xs="http://www.w3.org/2001/XMLSchema">

   <xs:element name="test">
<xs:annotation>

      <xs:documentation>Comment describing your root element</xs:documentation>

</xs:annotation>
<xs:complexType>

      <xs:sequence>
        <xs:element name="vecteur" type="cellule"/>
      </xs:sequence>

</xs:complexType>

  </xs:element>
  <xs:complexType name="cellule">
<xs:simpleContent>

      <xs:extension base="xs:float"/>
</xs:simpleContent>

  </xs:complexType>
</xs:schema>',
TRUE, TRUE, FALSE, FALSE);
end;

CREATE TABLE TEST1 (
ID NUMBER(9.0)
 CONSTRAINT pk_TEST1 PRIMARY KEY
 CONSTRAINT ck_TEST1_ID
 CHECK (ID >= 0),
DATA XMLTYPE
)
xmltype column DATA
XMLSCHEMA "http://www.ec-lille.fr/test1.xsd" element "test";

INSERT INTO TEST1 VALUES (
1,
XMLTYPE('<test xmlns:xdb="http://xmlns.oracle.com/xdb" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://www.ec-lille.fr/test1.xsd">   <vecteur>3.14159</vecteur>
</test>')
);

The result of the last SQL statement is:

ERREUR à la ligne 3 :

ORA-31038: Valeur number 3.14159 non valide
ORA-06512: à "SYS.XMLTYPE", ligne 0
ORA-06512: à ligne 1

(My Oracle Server is configured in French language :-)

I've looked at the posts in asktom.oracle.com but I haven't fond anything even remotely related to this issue.

Has anyone ever experienced the same issue, or is it a bug of this release of the Oracle ?

Thank you very much for your answers,

Ludovic Copéré Received on Fri Mar 07 2003 - 08:09:33 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US