W3C home > Mailing lists > Public > public-rdf-dawg-comments@w3.org > September 2011

Clarification needed on BIND

From: David Booth <david@dbooth.org>
Date: Wed, 07 Sep 2011 11:40:45 -0400
To: public-rdf-dawg-comments <public-rdf-dawg-comments@w3.org>
Message-ID: <1315410045.2882.10766.camel@dbooth-laptop>
Regarding sec 10.1 "BIND: Assigning to Variables":
http://www.w3.org/TR/sparql11-query/#bind

What happens if the same variable is bound more than once using BIND?
For example:

PREFIX  dc:  <http://purl.org/dc/elements/1.1/>
PREFIX  ns:  <http://example.org/ns#>
SELECT  ?title ?price
{  
   BIND (?title as "The World")
   BIND (?title as "The Universe")
   ?x dc:title ?title ; ns:price ?p .
}

Should this be handled as:

 - an error?

 - both bindings are used (to produce multiple solutions)?

 - The first or last BIND statement for ?title takes precedence?

It would be helpful to clarify this in the spec.

Thanks

-- 
David Booth, Ph.D.
http://dbooth.org/

Opinions expressed herein are those of the author and do not necessarily
reflect those of his employer.
Received on Wednesday, 7 September 2011 15:41:14 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 7 September 2011 15:41:15 GMT