W3C home > Mailing lists > Public > public-sparql-dev@w3.org > October to December 2010

Re: still not understanding FROM NAMED

From: Rob Vesse <rav08r@ecs.soton.ac.uk>
Date: Wed, 17 Nov 2010 09:24:23 +0000
To: Bob DuCharme <bob@snee.com>
Cc: <public-sparql-dev@w3.org>
Message-ID: <EMEW3|9737819cb7a6565be831b47332a596e3mAG9OQ06rav08r|ecs.soton.ac.uk|5583b84c26e5390d1bd13a2b9ed45f39@ecs.soton.ac.uk>
FROM NAMED specifies Graphs that are used in GRAPH clauses

e.g.

SELECT * FROM NAMED <http://example.org/myGraph> WHERE { ?s ?p ?o . GRAPH
?g { ?s ?x ?y }}

Would first find all triples from the default graph (which may in fact be
the union of several graphs) and then the GRAPH part would use Graphs
specified in FROM NAMED clauses to match additional triples.  At least
broadly speaking that is how it should work.  Actual implementations tend
to vary somewhat.

The difference should be that a FROM clause specifies a graph that forms
part of the default graph over which the query operates while the FROM
NAMED specifies Graphs used only in Graph clauses

Rob

On Tue, 16 Nov 2010 19:29:23 -0500, Bob DuCharme <bob@snee.com> wrote:
> I understand the various examples in the SPARQL spec that use FROM 
> NAMED, but I still don't completely understand what the FROM NAMED part 
> does, especially compared with FROM <http://some/uri>.
> 
> http://www.w3.org/TR/2010/WD-sparql11-query-20101014/#namedGraphs says 
> "A query can supply IRIs for the named graphs in the RDF Dataset using 
> the FROM NAMED clause." If they're named graphs, don't they already have 
> IRIs as names? What is FROM NAMED adding here?
> 
> thanks,
> 
> Bob

-- 
PhD Student
IAM Group
Bay 20, Room 4027, Building 32
Electronics & Computer Science
University of Southampton
Received on Wednesday, 17 November 2010 09:24:59 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 17 November 2010 09:25:00 GMT