[MarkLogic Dev General] XQuery schema aware queries
Punnoose, Roshan
punnooser at bah-systems.com
Mon Sep 24 13:56:18 PDT 2007
Hi,
I am trying to write a schema aware query; however, I am running into an
issue with data typing.
I have a query like this:
declare namespace base = "urn:espace-object-model:base"
declare namespace info1 ="urn:espace-object-model:source:info1"
declare namespace domain="urn:espace-object-model:domain"
for $d in
fn:collection("/urn:espace-domain-model:result-set/punnooser-e-space/376
66")/*/*[self::element(*, info1:InformationObjectTypeForInfo1)]
return $d
Which works, and brings back the all elements at that level of type="
info1:InformationObjectTypeForInfo1". This type is an schema extension
of base:InformationObjectType, and I want to run the same query, except
checking if the element is of base:InformationObjectType. However, this
does not work. Is there a reason that a schema extension type will not
pick up using this method? If so, is there another way I can perform the
same task, looking for all elements with type
base:InformationObjectType, even if it is an extension of the type?
Roshan
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Punnoose, Roshan.vcf
Type: text/x-vcard
Size: 179 bytes
Desc: Punnoose, Roshan.vcf
Url : http://xqzone.marklogic.com/pipermail/general/attachments/20070924/d1cbb5a0/PunnooseRoshan.vcf
More information about the General
mailing list