Unable To Query XML document with Namespace Declarations

Monday, 10 September 2012 · 3 messages
RG
Ramesh G10 Sep 2012 06:04 #

Hi All,

I am trying to query an XML document which has some namespace declarations. But, unfortunately the query is not giving any result.

When I try to execute the same query after removing the namespace declaration, everything works fine.

Is there any way to query the document with namespace declaration?

I am attaching the XML document for your reference.

Any help would be greatly appreciated.

Thanks,

Ramesh

CG
Christian Grün10 Sep 2012 06:06 #

Hi Ramesh,

have you specified the namespaces in your XQuery expression? As a shortcut, you may also use wildcards:

/*:this/*:may/*:help

Christian

Quoted text · Ramesh G · 25 lines
On Mon, Sep 10, 2012 at 6:04 AM, Ramesh G <ramesh.gubbala9 at gmail.com> wrote: > Hi All, > > I am trying to query an XML document which has some namespace > declarations. But, unfortunately the query is not giving any result. > > When I try to execute the same query after removing the namespace > declaration, everything works fine. > > Is there any way to query the document with namespace declaration? > > I am attaching the XML document for your reference. > > Any help would be greatly appreciated. > > Thanks, > > Ramesh > > > _______________________________________________ > BaseX-Talk mailing list > BaseX-Talk at mailman.uni-konstanz.de > https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk >
RG
Ramesh G10 Sep 2012 06:38 #

Hi Christian,

Thank you very much for the quick reply. Now everything is working fine.

Thanks, Ramesh.

On Mon, Sep 10, 2012 at 9:36 AM, Christian Grün <christian.gruen at gmail.com>wrote:

Quoted text · Christian Grün · 37 lines
> Hi Ramesh, > > have you specified the namespaces in your XQuery expression? > As a shortcut, you may also use wildcards: > > /*:this/*:may/*:help > > Christian > ___________________________ > > On Mon, Sep 10, 2012 at 6:04 AM, Ramesh G <ramesh.gubbala9 at gmail.com> > wrote: > > Hi All, > > > > I am trying to query an XML document which has some namespace > > declarations. But, unfortunately the query is not giving any result. > > > > When I try to execute the same query after removing the namespace > > declaration, everything works fine. > > > > Is there any way to query the document with namespace declaration? > > > > I am attaching the XML document for your reference. > > > > Any help would be greatly appreciated. > > > > Thanks, > > > > Ramesh > > > > > > _______________________________________________ > > BaseX-Talk mailing list > > BaseX-Talk at mailman.uni-konstanz.de > > https://mailman.uni-konstanz.de/mailman/listinfo/basex-talk > > >

⚡Generated with XQuery