Subject:[DataDirect][XQuery][err:FODC0005]Exception thrown by URIResolver: Author:Julio de la Vega Date:20 Dec 2007 07:18 AM Originally Posted: 20 Dec 2007 07:17 AM
Hi *,
I have developed an XQuery code that I would like to run in server side under DataDirectXQuery converter. I think that I have to set up my scenario properties according to DataDirectXQuery.
After setting up my scenario with processor type to DataDirectxQuery and running again my code, I got this error message:
[DataDirect][XQuery][err:FODC0005]Exception thrown by URIResolver:[DataDirect][XQuery]Error during conversion: Unable to open: \Server-hps\tecnico\Proyectos\Stylus\Desarrollos\SICAV\XQUERY\SICAVXQUERY.txt
This message does not appear when I run my code with built-in processor.
How do we have to set up our scenario to run this code under JAVA with DataDirectxQuery?
Code:
let $doc := doc('converter:file:///\\Server-hps\tecnico\Proyectos\Stylus\Desarrollos\SICAV\XQUERY\SICAVXQUERY.conv?file:///\\Server-hps\tecnico\Proyectos\Stylus\Desarrollos\SICAV\XQUERY\SICAVXQUERY.txt')
let $traducemes := doc(".\mes.xml")
return
<root>
{
for $REG_10 at $REG_10-startPos in $doc/root/REG_10
return
…
Subject:[DataDirect][XQuery][err:FODC0005]Exception thrown by URIResolver: Author:Minollo I. Date:20 Dec 2007 08:40 AM
Change:
let $doc := doc('converter:file:///\\Server-hps\tecnico\Proyectos\Stylus\Desarrollos\SICAV\XQUERY\SICAVXQUERY.conv?file:///\\Server-hps\tecnico\Proyectos\Stylus\Desarrollos\SICAV\XQUERY\SICAVXQUERY.txt')
into
let $doc := doc('converter:file://\\Server-hps\tecnico\Proyectos\Stylus\Desarrollos\SICAV\XQUERY\SICAVXQUERY.conv?file://\\Server-hps\tecnico\Proyectos\Stylus\Desarrollos\SICAV\XQUERY\SICAVXQUERY.txt')
Subject:[DataDirect][XQuery][err:FODC0005]Exception thrown by URIResolver: Author:Julio de la Vega Date:20 Dec 2007 09:04 AM
Hi Minollo,
First error message has disappeared but now, $traducemes gives a new error:
[DataDirect][XQuery][err:FODC0005]Exception returned by Adaptor (Streaming Adaptor) : java.io.FileNotFoundException: \Server-hps\Tecnico\Proyectos\Stylus\Desarrollos\SICAV\XQUERY\mes.xml (El sistema no puede hallar la ruta especificada)
(El sistema no puede hallar la ruta especificada) means that system can no find the path
Subject:[DataDirect][XQuery][err:FODC0005]Exception thrown by URIResolver: Author:Minollo I. Date:20 Dec 2007 09:14 AM
I guess your XQuery is in that same UNC location. That apparently is breaking the ability to resolve the relative path. We will look into it, but just be aware that DataDirect XQuery and XML Converters (the version used by XQuery, at least) are Java components; so, dealing with UNC paths may create troubles.
In the meanwhile, I can only suggest that you either reference mes.xml through an absolute path, or you don't use UNC paths.
Subject:[DataDirect][XQuery][err:FODC0005]Exception thrown by URIResolver: Author:Julio de la Vega Date:20 Dec 2007 10:01 AM
If I am using for my queries as input xml the result of the conversion from a custom conv file and a flat file. Which is the best option to call this information in my xQuery code if I will use my XQuery in a JAVA and DataDirectXQuery enviroment?
Custom CONV file and Flat file will generate big xml files (more than 1GB) Can I have any problem with memory?
Subject:[DataDirect][XQuery][err:FODC0005]Exception thrown by URIResolver: Author:Minollo I. Date:20 Dec 2007 10:13 AM
You are saying you need to do what your XQuery is already doing, right? Using the result of a custom conversion as input.
You can do that using the doc() function, as in your current code; or you can do that using an external variable and binding the result on the conversion dynamically to the variable through Java (the Java code generation utility in Stylus can help you with that, or we can send you a specific example if you need it).
If you are talking about using the result of an XQuery execution as input for another XQuery execution, that is possible too, in a scalable way.
All methods these are able to leverage the streaming and projection optimizations in DataDirect XQuery. Clearly, how scalable and fast the XQuery execution is against a large data sets also depends on what the XQuery itself is doing; but in general you have the most scalable and performant XML manipulation tool available on the market in your hands when you use DataDirect XQuery.