This is necessary on Windows.   Otherwise, the command-line parser in
windows gets screwed up.   It is a platform thing...

Mark

"Richard R. Liu" wrote:

> Try
>
> xindice xpath_query -c /db/klemens -q  "/[EMAIL PROTECTED]'120320']"
>
> i.e., double quotes around the query and single quotes within it.
>
> > -----Original Message-----
> > From: Rizwan Virk [mailto:[EMAIL PROTECTED]
> > Sent: Saturday, July 06, 2002 17:07
> > To: [email protected]
> > Subject: RE: XPATH usage
> >
> >
> > hi,
> >
> > try it with single quotes ... this makes a difference sometimes ...
> > /[EMAIL PROTECTED]'120320']
> >
> > Thanks
> > Riz
> >
> > ------------------------------
> > Riz Virk, (617) 905-3518
> > [EMAIL PROTECTED], [EMAIL PROTECTED]
> > http://www.xyztechnologies.com
> >
> >
> > -----Original Message-----
> > From: Dr. Klemens Waldh�r [mailto:[EMAIL PROTECTED]
> > Sent: Saturday, July 06, 2002 10:54 AM
> > To: [email protected]
> > Subject: XPATH usage
> >
> >
> > Hi,
> >
> > I tried several times to run the XPATH example given in the
> > user manual.
> > It does not seem to work.
> >
> > I imported several files. Also one with given in the manual. My
> > collectionn is called db/klemens.
> >
> > <?xml version="1.0"?>
> > <product product_id="120320">
> >    <description>Glazed Ham</description>
> > </product>
> >
> > Now when I search using
> >
> > c:\projects\perl\tm>xindice xpath_query -c /db/klemens -q
> > /[EMAIL PROTECTED]"120320"]
> >
> > ====> No result !
> >
> > If I use the following simple XPATH query instead:
> >
> > c:\projects\perl\tm>xindice xpath_query -c /db/klemens -q /product
> >
> > I get:
> >
> >
> > <?xml version="1.0"?> <product product_id="120320"
> > xmlns:src="http://xml.apache.org/xindice/Query"; sr:col="/db/klemens"
> > src:key="test3">
> >    <description>Glazed Ham</description>
> > </product>
> > c:\projects\perl\tm>
> >
> > It works ! Now what's wrong with the first query ? Do I have to create
> > an index ? I am really wondering.
> >
> > With regard to the article mentioned at XINDICE realm it
> > should work too
> > (Apache's Xindice Organizes XML Data Without Schema). The
> > example there
> > is as follows (although one has to adapt it because this is
> > not a valid
> > XML document and XINDICE recognises this bug)
> >
> > "     <?xml version="1.0"?>
> >      <product product_id="1" type="widget">
> >           <description>foo</description>
> >      </product>
> >      <product product_id="2" type="widget">
> >           <description>bar</description>
> >      </product>
> >      <product product_id="3" type="widget">
> >           <description>foobar</description>
> >      </product>
> >
> > And the author states: If I wanted to write an XPath query to
> > select the
> > second product, I could use the following query string:
> >      /[EMAIL PROTECTED]"2"]
> > "
> >
> > So theoretically my statement is correct.
> >
> > Thanks for your help !
> >
> > I also used the query in some of the browsers avalable for XINDICE and
> > it does not work either. Curiously other queries sometimes work,
> > sometimes not. And it hard to see why one query works and the
> > other not.
> >
> > Another question: Is there an easy way to check if XINDICE is
> > running or
> > not ? Idea is to check through the web if the server is running or not
> > on a specific machine.
> >
> > BTW: XINDICE is a cool tool.
> >
> > Klemens
> >
> >

--
Mark J Stang
System Architect
Cybershop Systems

begin:vcard 
n:Stang;Mark
x-mozilla-html:TRUE
adr:;;;;;;
version:2.1
email;internet:[EMAIL PROTECTED]
fn:Mark Stang
end:vcard

Reply via email to