You are viewing a plain text version of this content. The canonical link for it is here.
Posted to xindice-users@xml.apache.org by colle <co...@pi.be> on 2002/06/07 13:07:16 UTC
XML-RPC and ASP - xpath query question
Hello,
I' am trying to publish documents stored in xindice on an asp webpage. I use the asp xmlrpc implementation from David Carter-Tod (http://www.wcc.vccs.edu/dtod/XMLRPC/). I managed to make a connection (getdocumentcount), but running an xpath query didn't work. (I've already checked that query result isn't empty) Also, there isn't an error message when I ran the query.
What am I doing wrong?
Code:
<!--#include virtual="xmlrpcasp/code/xmlrpc.asp" -->
<%
Dim paramList(1)
paramList(0)="/db/test"
myresp = xmlRPC ("http://localhost:4080", "db.getDocumentCount", paramList)
Response.Write "<p>" & myresp & "</p>"
Dim para(4)
para(0)="/db/test"
para(1)="XPath"
para(2)="/nitf/head"
myresp2 = xmlRPC ("http://localhost:4080","db.queryDocument", para)
Response.Write "<b>" & myresp2 & " </b>"
%>
Thanks,
Arnoud
AW: XML-RPC and ASP - xpath query question
Posted by Daniel Kröger <Ze...@zesolo.net>.
Try this:
para(0)="/db/test"
para(1)="XPath"
para(2)="/nitf/head"
para(3)="{X => "http://www.xmldb.org/xpath"}"
para(4)="id of the doc"
myresp2 = xmlRPC ("http://localhost:4080","db.queryDocument", para)
Response.Write "<b>" & myresp2 & " </b>"
Note: para(3) has to be a hashtable!!
Daniel
Re: XML-RPC and ASP - xpath query question
Posted by colle <co...@pi.be>.
yep,
No diff with xpath
A
----- Original Message -----
From: "Daniel Kröger" <Ze...@zesolo.net>
To: <xi...@xml.apache.org>
Sent: Friday, June 07, 2002 1:24 PM
Subject: AW: XML-RPC and ASP - xpath query question
>
> >
> >
> > Hi,
> >
> > May be you could try "xpath" instead of "XPath". It's just a guess based
> > on xpath URL quiery syntax.
> >
> > Roman
>
> XPath should be OK!
>
> > >
> > > Code:
> > >
> > > <!--#include virtual="xmlrpcasp/code/xmlrpc.asp" -->
> > >
> > > <%
> > >
> > > Dim paramList(1)
> > >
> > > paramList(0)="/db/test"
> > >
> > > myresp = xmlRPC ("http://localhost:4080", "db.getDocumentCount",
> > > paramList)
> > >
> > > Response.Write "<p>" & myresp & "</p>"
> > >
> > > Dim para(4)
> > >
> > > para(0)="/db/test"
> > >
> > > para(1)="XPath"
> > >
> > > para(2)="/nitf/head"
> > >
> > > myresp2 = xmlRPC ("http://localhost:4080","db.queryDocument", para)
> > >
> > > Response.Write "<b>" & myresp2 & " </b>"
> > >
> > > %> Thanks,Arnoud
> >
>
>
> Is it possible, that you forgot some params?
> If your query a document, the method wants 5 params:
> collectionName,
> type,
> query,
> namespaces and
> id!
>
> Daniel
>
>
AW: XML-RPC and ASP - xpath query question
Posted by Daniel Kröger <Ze...@zesolo.net>.
>
>
> Hi,
>
> May be you could try "xpath" instead of "XPath". It's just a guess based
> on xpath URL quiery syntax.
>
> Roman
XPath should be OK!
> >
> > Code:
> >
> > <!--#include virtual="xmlrpcasp/code/xmlrpc.asp" -->
> >
> > <%
> >
> > Dim paramList(1)
> >
> > paramList(0)="/db/test"
> >
> > myresp = xmlRPC ("http://localhost:4080", "db.getDocumentCount",
> > paramList)
> >
> > Response.Write "<p>" & myresp & "</p>"
> >
> > Dim para(4)
> >
> > para(0)="/db/test"
> >
> > para(1)="XPath"
> >
> > para(2)="/nitf/head"
> >
> > myresp2 = xmlRPC ("http://localhost:4080","db.queryDocument", para)
> >
> > Response.Write "<b>" & myresp2 & " </b>"
> >
> > %> Thanks,Arnoud
>
Is it possible, that you forgot some params?
If your query a document, the method wants 5 params:
collectionName,
type,
query,
namespaces and
id!
Daniel
Re: XML-RPC and ASP - xpath query question
Posted by KOZLOV Roman <r-...@opencascade.com>.
Hi,
May be you could try "xpath" instead of "XPath". It's just a guess based
on xpath URL quiery syntax.
Roman
colle wrote:
> Hello,
>
> <?xml:namespace prefix = o ns =
> "urn:schemas-microsoft-com:office:office" />
>
> I am trying to publish documents stored in xindice on an asp webpage.
> I use the asp xmlrpc implementation from David Carter-Tod
> (http://www.wcc.vccs.edu/dtod/XMLRPC/). I managed to make a connection
> (getdocumentcount), but running an xpath query didnt work. (I've
> already checked that query result isn't empty) Also, there isnt an
> error message when I ran the query.
>
> What am I doing wrong?
>
> Code:
>
> <!--#include virtual="xmlrpcasp/code/xmlrpc.asp" -->
>
> <%
>
> Dim paramList(1)
>
> paramList(0)="/db/test"
>
> myresp = xmlRPC ("http://localhost:4080", "db.getDocumentCount",
> paramList)
>
> Response.Write "<p>" & myresp & "</p>"
>
> Dim para(4)
>
> para(0)="/db/test"
>
> para(1)="XPath"
>
> para(2)="/nitf/head"
>
> myresp2 = xmlRPC ("http://localhost:4080","db.queryDocument", para)
>
> Response.Write "<b>" & myresp2 & " </b>"
>
> %> Thanks,Arnoud