Skip to content

Commit

Permalink
Use reified triples in examples
Browse files Browse the repository at this point in the history
  • Loading branch information
rubensworks committed Aug 21, 2024
1 parent 72b9e2c commit 118528f
Showing 1 changed file with 17 additions and 11 deletions.
28 changes: 17 additions & 11 deletions spec/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7406,8 +7406,8 @@ <h5>TZ</h5>
</section>

<!-- QT -->
<section id="func-triple-terms">
<h4>Functions on Triple Terms</h4>
<section id="func-reified-triples">
<h4>Functions on Reified Triples</h4>
<section id="func-triple">
<h5>TRIPLE</h5>
<pre class="prototype nohighlight">
Expand Down Expand Up @@ -7439,7 +7439,7 @@ <h5>TRIPLE</h5>
<p>
As a shorthand notation, the <code>TRIPLE</code> function
can also be written in the form of a
<a href="#rExprQuotedTriple">triple term expression</a>
<a href="#rExprTripleTerm">triple term expression</a>
using <code>&lt;&lt;(</code> and <code>)&gt;&gt;</code>. There is a
syntax limitation to this shorthand form: the three elements of
the triple term expression can only be variables and directly
Expand All @@ -7449,18 +7449,24 @@ <h5>TRIPLE</h5>
</p>
<pre class="query nohighlight">
PREFIX : &lt;http://example/&gt;
PREFIX rdf: &lt;http://www.w3.org/1999/02/22-rdf-syntax-ns#&gt;

SELECT ?s ?date {
?s ?p ?o
BIND( &lt;&lt;( ?s ?p ?o )&gt;&gt; AS ?qt )
?qt :tripleAdded ?date
?s ?p ?o .
BIND( &lt;&lt;( ?s ?p ?o )&gt;&gt; AS ?tt )
:myreifier rdf:reifies ?tt .
:myreifier :tripleAdded ?date .
}
</pre>
<pre class="query nohighlight">
PREFIX : &lt;http://example/&gt;
PREFIX rdf: &lt;http://www.w3.org/1999/02/22-rdf-syntax-ns#&gt;

SELECT ?s ?date {
?s ?p ?o
BIND( TRIPLE(?s, ?p, ?o) AS ?qt )
?qt :tripleAdded ?date
?s ?p ?o .
BIND( TRIPLE(?s, ?p, ?o) AS ?tt )
:myreifier rdf:reifies ?tt .
:myreifier :tripleAdded ?date .
}
</pre>
</section>
Expand Down Expand Up @@ -11805,10 +11811,10 @@ <h2>Changes between SPARQL 1.1 Query Language and SPARQL 1.2 Query Language</h2>
Normative changes:
<ul>
<li>Remove concepts of plain and simple literals, in favor of explicit mentions of xsd:string</li>
<li>Update grammar for triple terms and triple functions in <a href="#sparqlGrammar" class="sectionRef"></a></li>
<li>Update grammar for reified triples and triple functions in <a href="#sparqlGrammar" class="sectionRef"></a></li>
<li>Migrate XML Schema references to 1.1</li>
<li>Update references to XPath from 2.0 to 3.1</li>
<li>Add functions on triple terms to <a href="#func-triple-terms" class="sectionRef"></a></li>
<li>Add functions on reified triples to <a href="#func-reified-triples" class="sectionRef"></a></li>
</ul>
</li>
<li>
Expand Down

0 comments on commit 118528f

Please sign in to comment.