Project

Profile

Help

xml:id + XQuery bug?

Added by Anonymous about 19 years ago

Legacy ID: #3436154 Legacy Poster: David Sewell (dsew)

Platform: Saxon 8.5.1 under OS X Given a file "test.xml" with this content: <?xml version="1.0"?> <foo> <bar xml:id="n123">test</bar> </foo> this XQuery code performs as expected, returning the document node: declare variable $doc := doc("test.xml"); $doc but the following XQuery code declare variable $doc := <foo> <bar xml:id="n123">test</bar> </foo>; $doc returns an error: Error on line 3 column 1 of file:[...URL to my file...]: XQST0082: XQuery static error in #...= <foo> <bar xml:id="n123">#: Value of xml:id must be a valid NCName Failed to compile query Bug? 'n123' is certainly a valid NCName.


Replies (1)

RE: xml:id + XQuery bug? - Added by Anonymous about 19 years ago

Legacy ID: #3436386 Legacy Poster: Michael Kay (mhkay)

Although I can't find any record of this particular bug, it seems to have been fixed in Saxon 8.6, so I suggest you move to that version. Michael Kay

    (1-1/1)

    Please register to reply