[XQuery Talk Mailing List Archive Home] [By Date] [By Thread] [By Subject] [By Author] [Recent Entries] [Reply To This Message]

Galax, XQuery! and schema type matching

Vitali Gontsharuk vitali.gontsharuk at gmail.com
Fri Jun 8 10:24:28 PDT 2007


  Galax
Hello!

I'm having two problems which I could not solve until now.

The first problem is the following: schema type matching doesn't work for me
in typeswitch constructs. By that I mean constructs of the following form:

typeswitch ($elem)
case element(*, asdf:type1) return element type1 {}
case element(*, asdf:type2) return element type2 {}
default return element default {}

Here, asdf is the namespace prefix of the imported schema. I've tried this
both with the schema-aware version of saxon and with Galax. I'm doing this
the way this is described in the XQuery spec. Could someone please point me
to the problem by giving a working example. Because Saxon is a 100%
standard-conform XQuery implementation, I assume that I've made some
syntactical mistake.

The second problem is about the XQuery! implementation in Galax. I'm using
this XQuery extension to make changes in the XML node sets but this doesn't
work for me. Here is the example which I'm testing with. It has been
published in a presentation by Jerome Simeon (one of the leaders of the
Galax project). Here is the script:

(: Declare our counter :)
declare variable $counter := element counter { 0 };

(: Increment the counter :)
declare function local:getnext() as xs:integer {
 replace { $counter/node() } with { $counter/node() + 1 },
 $counter
};

I'm getting the following error:

Lexing Error: 3 Found QName while in operator state [File "bib.xq", line 6,

characters 9-10:]

I'm using the following command to interpret this script:

galax-run -output-xml bib.xml.result.xml -language xquerybang bib.xq

Here is the link to the presentation by Jerome Simeon from which I extracted
the above sample script:
http://xquerybang.cs.washington.edu/papers/xquerybang-psd.pdf

I will be thankful for any hint from your side! I already tried posting this
problem to the galax mailing list but didn't get any answer. The activity of
the project seems to be down somehow... There was also no reaction to my bug
report in their bugzilla for about two weeks. Does anyone know about the
status of the project? There has still been an update of galax in February
2007, so someone is still working on it...

I would also be thankful for the current state of the XQuery update facility
implementations or implementations of some alternative XQuery update
extension.

Thanks in advance for your answers!
Vitali Gontsharuk
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://x-query.com/pipermail/talk/attachments/20070608/2eb9d4c9/attachment.htm


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2007 All Rights Reserved.