Help:SPARQL query examples: Difference between revisions

From DataTrek
Jump to navigation Jump to search
No edit summary
(Redirected page to Help:Esempi query SPARQL)
Tag: New redirect
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
__NOTOC__
#REDIRECT [[Help:Esempi query SPARQL]]
<div class="mw-heading mw-heading2">
  <h2>Queries with cats</h2>
</div>
<div class="mw-heading mw-heading3">
  <h3>Cats</h3>
</div>
<syntaxhighlight lang="sparql">
SELECT ?cat ?catLabel WHERE {
  ?cat prefix:P1 prefix:Q2
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],mul,en". }
}
</syntaxhighlight>
 
<div class="mw-heading mw-heading2">
  <h2>Queries with dogs</h2>
</div>
<div class="mw-heading mw-heading3">
  <h3>Dogs</h3>
</div>
<syntaxhighlight lang="sparql">
SELECT ?dog ?dogLabel WHERE {
  ?dog prefix:P1 prefix:Q3
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],mul,en". }
}
</syntaxhighlight>
 
 
== Queries with dogs ==
=== Dogs ===
<syntaxhighlight lang="sparql">
SELECT ?dog ?dogLabel WHERE {
  ?dog prefix:P1 prefix:Q3
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],mul,en". }
}
</syntaxhighlight>

Latest revision as of 00:29, 10 January 2025