Hi Leonard
Thanks for quick reaction. And for hint how to work around
it.
I modified my query to specify the collection explicitly and
as it can be run without open database, it returns proper
results.
Thanks
And Merry Christmas to all of you. It is time to
exchange our XML trees to Christmas one. And let queries to this
tree brings proper results, you may enjoy.
Jan
2010/12/23 Leonard Wörteler
<leonard.woerteler@uni-konstanz.de>
Hi Jan,
Am 23.12.2010 16:56, schrieb Jan Vlčinský (CAD):
> I wonder, what I am doing wrong. Any
advice?
that seems to be a bug. I lack the time to investigate this
right now,
but here's a minimal example for others to test:
> (<foo key='a'/>)[@key = 'a']
When I do this without an open ducument, it runs fine, but
with an open
collection, this happens:
> Compiling:
> - removing unknown tag/attribute "key"
> - pre-evaluating () = "a"
> - Filter expression: removing false()
> Result: ()
And finally, with an open one-document DB:
> Error: Possible bug? Your feedback is welcome:
> Contact: basex-talk@mailman.uni-konstanz.de
> Version: BaseX 6.3.5
> Java: Sun Microsystems Inc., 1.6.0_22
> OS: Windows Vista, amd64
> Stack Trace:
> java.lang.NullPointerException
>
org.basex.query.QueryResources.docNodes(QueryResources.java:215)
>
org.basex.query.QueryResources.data(QueryResources.java:192)
> org.basex.query.path.NameTest.comp(NameTest.java:61)
> org.basex.query.path.AxisStep.comp(AxisStep.java:81)
>
org.basex.query.path.AxisPath.compPath(AxisPath.java:160)
> org.basex.query.path.Path.comp(Path.java:46)
> org.basex.query.expr.Arr.comp(Arr.java:35)
> org.basex.query.expr.CmpG.comp(CmpG.java:118)
> org.basex.query.expr.Preds.comp(Preds.java:47)
> org.basex.query.expr.Filter.comp(Filter.java:55)
>
org.basex.query.QueryContext.compile(QueryContext.java:208)
>
org.basex.query.QueryProcessor.compile(QueryProcessor.java:82)
> org.basex.core.cmd.AQuery.query(AQuery.java:75)
> org.basex.core.cmd.XQuery.run(XQuery.java:22)
> org.basex.core.Command.run(Command.java:292)
> org.basex.core.Command.exec(Command.java:274)
> org.basex.core.Command.execute(Command.java:67)
> org.basex.gui.GUI.exec(GUI.java:391)
> org.basex.gui.GUI$5.run(GUI.java:351)
I used the GUI from the current repository revision for
testing.
Cheers Leo
_______________________________________________
BaseX-Talk mailing list
BaseX-Talk@mailman.uni-konstanz.de
https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk
--
_______________________________________________
BaseX-Talk mailing list
BaseX-Talk@mailman.uni-konstanz.de
https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk