Hello,
I want to fire an XQuery across multiple databases. how to achieve this ?
Hi Kunal,
the easiest solution is to check our documentation... ;)
http://docs.basex.org/wiki/Databases http://docs.basex.org/wiki/Database_Module#db:open
Best, Christian
Hi Christian,
Thanks for sharing the documentation link. :)
I have gone through the documentation and reach to the conclusion that we can fire XQueries only on one DB at a time. we cannot run query across the DBs.
*For eg.* I am maintaining two DBs. DB 1: contains schema files. DB 2: contatins corresponding xmls.
I wont be able to fire a query obtaining datatype of an element which are specified in an xmls. ("let $ele := transaction/*[name() ne 'traInfo'] return xs:schema/xs:element[@name = $ele/local-name() and @type = 'xs:string']")
Above query will return all the elements defined in xml file which are of string datatype.
please correct me if I am wrong.
Thanks, Kunal
On Wed, Aug 27, 2014 at 8:24 PM, Christian Grün christian.gruen@gmail.com wrote:
Hi Kunal,
the easiest solution is to check our documentation... ;)
http://docs.basex.org/wiki/Databases http://docs.basex.org/wiki/Database_Module#db:open
Best, Christian
Did you try db:open()?
Best, Christian
On Thu, Aug 28, 2014 at 9:15 AM, Kunal Chauhan mail4ck@gmail.com wrote:
Hi Christian,
Thanks for sharing the documentation link. :)
I have gone through the documentation and reach to the conclusion that we can fire XQueries only on one DB at a time. we cannot run query across the DBs.
For eg. I am maintaining two DBs. DB 1: contains schema files. DB 2: contatins corresponding xmls.
I wont be able to fire a query obtaining datatype of an element which are specified in an xmls. ("let $ele := transaction/*[name() ne 'traInfo'] return xs:schema/xs:element[@name = $ele/local-name() and @type = 'xs:string']")
Above query will return all the elements defined in xml file which are of string datatype.
please correct me if I am wrong.
Thanks, Kunal
On Wed, Aug 27, 2014 at 8:24 PM, Christian Grün christian.gruen@gmail.com wrote:
Hi Kunal,
the easiest solution is to check our documentation... ;)
http://docs.basex.org/wiki/Databases http://docs.basex.org/wiki/Database_Module#db:open
Best, Christian
-- Kunal Chauhan mail4ck@gmail.com [+918655517141]
basex-talk@mailman.uni-konstanz.de