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

SPARQL vnext new feature?

From: Alan Ruttenberg <alanruttenberg@gmail.com>
Date: Sat, 3 Nov 2007 18:59:11 -0400
Message-ID: <29af5e2d0711031559h39fc85f9s846ade7165430990@mail.gmail.com>
To: public-sparql-dev@w3.org
Was playing around with SPARQL's grammar courtesy of Eric Prud'Hommeaux and
we checked what needed to be done to facilitate more concise queries against
remote endpoints.

Eric changed:

[9]     DatasetClause     ::=       'FROM' ( DefaultGraphClause |
NamedGraphClause |   'CONSTRUCT' ConstructTemplate DatasetClause*
WhereClause )

to allow

SELECT ?a ?b
  FROM ( CONSTRUCT { ?d <b> ?b }
                          FROM <http://example.com/sparql?>
                        WHERE { ?b <b> ?d } )
 WHERE { ?a <b> ?b }

The idea is that currently one has to do something like

SELECT ?a ?b
WHERE
   {
        GRAPH <http://example.com/sparql?query=CONSTRUCT%20%7B%20%3Fd
%20%3Cb%3E%20%3Fb%20%7D%20FROM%20%3Casdf%3E%20WHERE%20%7B%20%3Fb%20%
3Cb%3E%20%3Fd%20%7D%20&format=text%2Frdf%2Bn3>
        { ?b <b> ?d.}
{ ?a <b> ?b }
   }

Which is somewhat less likely to be written.

-Alan
Received on Saturday, 3 November 2007 23:20:26 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:17:05 GMT