[xquery-talk] module path question

Charlie c_z90 at yahoo.com
Fri Mar 23 06:53:49 PST 2007


Here is the result I got, and it complains about
missing the file qmodule/source.xml.

I tried 8.9J and it works...

$java -cp $SLAB/lib/saxon8.jar net.sf.saxon.Query -t
/tmp/testsuite/qmodule/qmodule002.xq 
Saxon 8.7J from Saxonica
Java version 1.5.0_07
Compiling query from
/tmp/testsuite/qmodule/qmodule002.xq
Compilation time: 257 milliseconds
Error on line 4 of
file:/tmp/testsuite/qmodule/dir/xmodule002b.xq:
  FODC0005: java.io.FileNotFoundException:
/tmp/testsuite/qmodule/source.xml (No such file
  or directory)
Error on line 3 of
file:/tmp/testsuite/qmodule/dir/xmodule002b.xq:
  net.sf.saxon.trans.DynamicError:
java.io.FileNotFoundException:
  /tmp/testsuite/qmodule/source.xml (No such file or
directory)
Query processing failed: Run-time errors were reported


--- Michael Kay <mike at saxonica.com> wrote:

> > But I used the following command and still got the
> error.
> >     java -cp $LIB/saxon8.jar net.sf.saxon.Query
> master.xquery
> > 
> > Mike could you please share your cmd?
> > 
> 
> There's nothing special about the command. I've got
> 
> c:\tests\testsuite\qmodule002.xq:
> =================================
> 
> (: MAIN MODULE :)
> 
> declare namespace ns1 = "namespace/ns1";
> 
> import module namespace ns2 = "namespace/ns2" at
> "dir/xmodule002b.xq";
> ns2:fun1()
> 
> c:\tests\testsuite\dir\xmodule002b.xq
> =====================================
> 
> module namespace ns2 = "namespace/ns2";
> 
> declare function ns2:fun1() {
> 	doc('source.xml')
> };
> 
> c:\tests\testsuite\dir\source.xml
> =================================
> 
> <any-source/>
> 
> and I do 
> 
> java -cp c:\saxon-build\8.7.3\bj\saxon8.jar
> net.sf.saxon.Query -t
> c:\tests\testsuite\qmodule\qmodule002.xq
> 
> and it displays <any-source/>
> 
> Michael Kay
> http://www.saxonica.com/
> 
> 



 
____________________________________________________________________________________
Be a PS3 game guru.
Get your game face on with the latest PS3 news and previews at Yahoo! Games.
http://videogames.yahoo.com/platform?platform=120121


More information about the talk mailing list