<div dir="ltr">Hi Joe,<div><br></div><div>I agree with Mike. Also, I noticed that you are declaring your program as XQuery 3.0. As far as I know, the XQuery Update 3.0 specification is still a Working Draft ( <a href="https://www.w3.org/TR/xquery-update-30/">https://www.w3.org/TR/xquery-update-30/</a> ). I would advise proceeding with care if you combine new XQuery 3.0 constructs with updates.</div><div><br></div><div>Kind regards,</div><div>Ghislain</div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jun 10, 2016 at 10:39 AM, Michael Kay <span dir="ltr"><<a href="mailto:mike@saxonica.com" target="_blank">mike@saxonica.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word"><div>I've logged this as a Saxon issue here:</div><div><br></div><div><a href="https://saxonica.plan.io/issues/2789" target="_blank">https://saxonica.plan.io/issues/2789</a></div><div><br></div><div>and you can track progress on it there by registering and doing a "watch" (the icon for that in Redmine is a five-pointed star, as anyone would guess).</div><div><br></div><div>I'm afraid my first attempts threw up several different symptoms which may or may not turn out to be relevant to the problem that you experienced. As I mentioned, XQuery Update doesn't get exercised very much except for running the limited W3C test suite and a very small batch of unit tests when we make a release.</div><div><br></div><div>Michael Kay</div><div>Saxonica</div><div><br></div><br><div><blockquote type="cite"><span class=""><div>On 9 Jun 2016, at 23:53, Joe Wicentowski <<a href="mailto:joewiz@gmail.com" target="_blank">joewiz@gmail.com</a>> wrote:</div><br></span><div><div><div class="h5"><div dir="ltr">Hi all,<div><br></div><div>I'm struggling with an XQuery Update problem which is corrupting the file I'm trying to update.  I've posted my code samples to <a href="https://gist.github.com/joewiz/2369367de3babba30e0aad8c9beec893" target="_blank">https://gist.github.com/joewiz/2369367de3babba30e0aad8c9beec893</a> - but here's the core of the issue:</div><div><br></div><div><div>I'm working with a TEI document containing <ref> elements that I'm trying to manipulate with XQuery Update. Specifically, I'm grabbing a page number reference from the text node immediately following the <ref> element, and I want to move the page number inside the <ref> element. (I'm actually trying to do a few more things, but I've reduced the sample code to do just this, because it illustrates the problem I'm facing.)</div><div><br></div><div>The problem is that the XQuery Update statement corrupts my file. The resulting file has 0 bytes. When I comment out the XQuery Update statement and uncomment the $test variable in the return expression, I get expected results, so I think the logic is sound. I have a feeling that the problem may have to do with line 25, where I add attributes to an element; when I comment out this, the corruption doesn't occur. But I need the attributes in that line. So I'm stumped. I've never encountered data corruption with XQuery Update, so I really hope there's a solution.</div><div><br></div><div>I'm using Saxon-EE XQuery 9.6.0.7 inside of oXygen 17.1, with Saxon's options for XQuery 3.0 and XQuery Update enabled.</div></div><div><br></div><div>Many thanks for any suggestions,</div><div>Joe</div></div></div></div>
_______________________________________________<br><a href="mailto:talk@x-query.com" target="_blank">talk@x-query.com</a><br><a href="http://x-query.com/mailman/listinfo/talk" target="_blank">http://x-query.com/mailman/listinfo/talk</a></div></blockquote></div><br></div><br>_______________________________________________<br>
<a href="mailto:talk@x-query.com">talk@x-query.com</a><br>
<a href="http://x-query.com/mailman/listinfo/talk" rel="noreferrer" target="_blank">http://x-query.com/mailman/listinfo/talk</a><br></blockquote></div><br></div>