Template

SPARQL2: Difference between revisions

(replace with MediaWiki version)
(simplified by removing documentation)
Line 1: Line 1:
<noinclude>
<!--
<languages/>
</noinclude><!--
-->{{ItemOrNot|Items used|{{#invoke:SPARQL|getItems|{{{query}}} }} }}
-->{{ItemOrNot|Items used|{{#invoke:SPARQL|getItems|{{{query}}} }} }}
{{ItemOrNot|Properties used|{{#invoke:SPARQL|getProperties|{{{query}}} }} }}
{{ItemOrNot|Properties used|{{#invoke:SPARQL|getProperties|{{{query}}} }} }}
{{#tag:syntaxhighlight|{{SPARQLText|query={{{query}}}|extraprefix={{{extraprefix|}}} }}|lang="sparql"}}
{{#tag:syntaxhighlight|{{SPARQLText|query={{{query}}}|extraprefix={{{extraprefix|}}} }}|lang="sparql"}}
[http://query.graphit.ur.de/#{{urlencode: {{SPARQLText|query={{{query}}}|extraprefix={{{extraprefix|}}} }} | PATH }} <translate><!--T:1--> Try it!</translate>]<!--
[http://query.graphit.ur.de/#{{urlencode: {{SPARQLText|query={{{query}}}|extraprefix={{{extraprefix|}}} }} | PATH }} Try it!]
--><noinclude>
{{documentation|content=
{{lua|Module:SPARQL}}
<templatedata>
{
"params": {
"query": {
"required": true,
"label": "query",
"description": {
"en": "SPARQL query",
"fr": "Requête SPARQL"
},
"example": "SELECT * WHERE { ?x wdt:P31 wd:Q5 } LIMIT 1",
"type": "string"
},
"extraprefix": {
"description": {
"en": "Extra prefixes to be added",
"fr": "Préfixes supplémentaires à ajouter"
},
"example": "PREFIX wikibase: <http://wikiba.se/ontology#>",
"type": "string"
}
},
"description": {
"en": "This template displays SPARQL query with syntax highlighting, used items and link to WDQS query site to run the query. \nTODO: used items labels are not localized",
"fr": "Ce modèle affiche la requête SPARQL en mettant en valeur la syntaxe, les éléments utilisés ainsi que le lien vers les site WDQS pour exécuter la commande."
},
"paramOrder": [
"query",
"extraprefix"
],
"format": "block"
}
</templatedata>
 
}}
</noinclude>

Revision as of 10:48, 31 May 2023



{{{query}}}

Try it!