On 02/06/11 13:33, Rob Vesse wrote:
Hi
You can use SERVICE ?var to specify that the query goes to multiple
endpoints defined as the URIs bound to ?var at execution time. You just
need to write your query such that ?var will be bound when you hit the
SERVICE clause. You can always add some Triples into your local dataset
specifically for this purpose and just include the patterns to select the
appropriate endpoints as part of your query.
One way to do that is:
{ BIND(<serviceURL_1> AS ?s) } UNION { BIND(<serviceURL_2> AS ?s) }
before
SERVICE ?s
Alternatively I think you can pre-bind a variable prior to executing the
query so you could inject the endpoints manually into the query by binding
to ?var but I don't know how to do that in ARQ myself.
At the moment, in ARQ, only one binding can be given to pre-bind names -
you can of course loop in the application.
What does not work in strict SPARQL is using BINDINGs.
The data table BINDINGs provides is joined with the results of the query
so it does not set the variables before SERVICE is called. Some would
call that a deficiency.
Andy
Regards,
Rob Vesse
p.s. The mailing list has moved to [email protected]