- From: Seaborne, Andy <andy.seaborne@hp.com>
- Date: Fri, 03 Jun 2005 17:36:39 +0100
- To: "Eric Prud'hommeaux" <eric@w3.org>
- CC: Dan Connolly <connolly@w3.org>, RDF Data Access Working Group <public-rdf-dawg@w3.org>
I noted in a reply to Yoshio http://lists.w3.org/Archives/Public/public-rdf-dawg/2005AprJun/0296.html that rq23 was unclear as to make might happen if the service has a dataset AND the query specifies one. I suggested that, in the same way that the protocol overrides the query, the query should override the service dataset (or be rejected). This was the intent behind saying a "dataset description". If the service uses a different dataset to that asked for, it is wrong in some sense. Andy Eric Prud'hommeaux wrote: > On Thu, Jun 02, 2005 at 09:29:09AM -0500, Dan Connolly wrote: > >>On Thu, 2005-06-02 at 07:35 -0400, Eric Prud'hommeaux wrote: >> >>>This is kind of like a test case for fromUnionQuery, hence the >>>threading choice. >>> >>>Using Named Graphs (rq23) parlance, if I have a dataset: >>> >>> default: { } >>> <lies.rdf>: { <TheMoon> <isMadeOf> <GreenCheese> } >>> <truth.rdf>: { <TheMoon> <isMadeOf> <Rocks>, <Dirt> } > > > Perhaps i over-abbreviated. This particular query service has no > innate data (unlike, say, a database of the CIA World Fact Book). > There are also two rdf files, lies and truth, out there on the web. > > >>>and a query: >>> >>> SELECT ?stuff >>> FROM <truth.rdf> > > > per rq23, reads <truth.rdf> into the default graph. > > >>> FROM NAMED <lies.rdf> > > > reads <lies.rdf> into a named graph called <lies.rdf>. > > >>> WHERE { <TheMoon> <isMadeOf> ?stuff } >>> >>>I get pretty predictable results: >>> >>> | Rocks | >>> | Dirt | >> >>Huh? Above you said the default graph was empty. So >>you should get no results. >> >>Your example has two conflicting descriptions of >>the dataset. Pick one, please. >> >>If you pick the one suggested by the FROM/FROM NAMED >>parts of the query, you get: >> >> default: { <TheMoon> <isMadeOf> <Rocks>, <Dirt> } >> <lies.rdf>: { <TheMoon> <isMadeOf> <GreenCheese> } >> <truth.rdf>: { <TheMoon> <isMadeOf> <Rocks>, <Dirt> } >> >> >> >> >>>But the default graph need not start out empty. >> >>"start out"? datasets don't change. They just are. > > > The notional SPARQL interface to W3C mail search is a service that > starts out with some amount of innate data. It could be in named > graphs or in the default graph. Both FROM and FROM NAMED change the > data that is available to the query. > > >>> If i happen on a default >>>graph that alreay has <lies.rdf> in it: >>> >>> default: { <TheMoon> <isMadeOf> <GreenCheese> } >>> >>>and do the same query, I get: >>> >>> | Rocks | >>> | Dirt | >>> | GreenCheese | >>> >>>Thus, if the defualt database *may* be contiminated, you need to fall >>>back to the more verbose form of provenance constraint: >>> SELECT ?stuff >>> FROM <truth.rdf> >>> FROM NAMED <lies.rdf> >>> WHERE { GRAPH <truth.rdf> { <TheMoon> <isMadeOf> ?stuff } } >>> > >
Received on Friday, 3 June 2005 16:37:08 UTC