W3C home > Mailing lists > Public > public-rdf-dawg@w3.org > April to June 2004

Re: RDF QLs within a larger language

From: Jos De_Roo <jos.deroo@agfa.com>
Date: Mon, 28 Jun 2004 23:45:24 +0200
To: eric@w3.org
Cc: public-rdf-dawg@w3.org
Message-ID: <OFDF264C31.0866382E-ONC1256EC1.00706484-C1256EC1.0077836A@agfa.com>

EricP wrote:
> Howard's XSRQL [1] and TimBL's N3QL [2] are good examples of RDF
> functions that fit into a larger QL. In the XSRQL case, it gives us
> an opportunity to lean on some already specified and implemented
> functionality in XQuery that is likely to get very wide
> deployment. I'm curious about how much re-use we get, Howard.
> N3QL constrains itself to be a subset of the N3 syntax which can be
> used for query. This is especially usful if N3 is later adopted as a
> rules language because we would get to take advantage of the fact that
> query goals and rule goals are very similar, both in syntax and in
> semantics. Once we've defined a language that produces some sort of
> variable bindings, it's pretty easy to define how to use those
> bindings to construct new graphs.
> Anybody interested in exploring this with me?

yes, I do
started some testing..
seems pretty straightforward to map
--query testQ.n3
--filter testF.n3

[] select { result is (?x ?y) };
   where  { ?x a ex:Librarian;  ex:hairColor ?y }.
{ ?x a ex:Librarian;  ex:hairColor ?y } => { result is (?x ?y) }.

for the moment I assume it is q:result and q:is where
@prefix q: <http://www.w3.org/2004/ql#>

and then given

ex:Joe a ex:Librarian; ex:hairColor "black".
ex:Mary a ex:Librarian; ex:hairColor "red".

we indeed get

q:result q:is (ex:Joe "black").
q:result q:is (ex:Mary "red").

?? how about what we had before as
{ ?x a ex:Librarian; ex:hairColor ?y } => { result is (?x ?y) }.
{ ?x a ex:Plumber; ex:hairColor ?y } => { result is (?x ?y) }.


> [1] http://www.fatdog.com/xsrql.html#Examples
> [2] http://www.w3.org/DesignIssues/N3QL

Jos De Roo, AGFA http://www.agfa.com/w3c/jdroo/
Received on Monday, 28 June 2004 17:46:03 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 17:00:27 UTC