Public bug reported:

I think that the following query should return xs:integer, but it
returns xs:untypedAtomic.

import module namespace schema = "http://www.zorba-
xquery.com/modules/schema";

declare variable $doc :=
<numbers xmlns:xs="http://www.w3.org/2001/XMLSchema";
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>
<xs_long xsi:type="xs:long">1</xs_long>
<xs_long xsi:type="xs:integer">2</xs_long>
<xs_long>3</xs_long>
</numbers>
;


declare variable $vdoc := validate lax { $doc };

schema:schema-type(data(($vdoc//xs_long)[2]))

** Affects: zorba
     Importance: High
     Assignee: Cezar Andrei (cezar-andrei)
         Status: New

-- 
You received this bug notification because you are a member of Zorba
Coders, which is the registrant for Zorba.
https://bugs.launchpad.net/bugs/1023362

Title:
  xsi:type attribute ignored during validation

Status in Zorba - The XQuery Processor:
  New

Bug description:
  I think that the following query should return xs:integer, but it
  returns xs:untypedAtomic.

  import module namespace schema = "http://www.zorba-
  xquery.com/modules/schema";

  declare variable $doc :=
  <numbers xmlns:xs="http://www.w3.org/2001/XMLSchema";
           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>
  <xs_long xsi:type="xs:long">1</xs_long>
  <xs_long xsi:type="xs:integer">2</xs_long>
  <xs_long>3</xs_long>
  </numbers>
  ;

  
  declare variable $vdoc := validate lax { $doc };

  schema:schema-type(data(($vdoc//xs_long)[2]))

To manage notifications about this bug go to:
https://bugs.launchpad.net/zorba/+bug/1023362/+subscriptions

-- 
Mailing list: https://launchpad.net/~zorba-coders
Post to     : zorba-coders@lists.launchpad.net
Unsubscribe : https://launchpad.net/~zorba-coders
More help   : https://help.launchpad.net/ListHelp

Reply via email to