Mercurial > repos > saml > semweb_tools
view sparql_import.xml @ 5:eee537fd4600 draft default tip
Uploaded
author | saml |
---|---|
date | Wed, 21 Nov 2012 12:55:30 -0500 |
parents | 62cfd14e2520 |
children |
line wrap: on
line source
<tool id="sparql_import" name="SPARQL Import" version="1.0.0"> <description>Import data from a SPARQL Endpoint</description> <command interpreter="python">sparql_import.py -u $url -q "$sparqlquery" -o $outfile</command> <inputs> <param name="url" type="text" format="text" size="80" label="SPARQL Endpoint URL"/> <param name="sparqlquery" type="text" format="text" area="True" size="5x80" label="SPARQL Query"/> </inputs> <outputs> <data name="outfile" format="tabular"/> </outputs> <help> **What it does** The SPARQL import executes a SPARQL query against a SPARQL endpoint and returns the results in tabular format, with one column per variable in the SPARQL query. ------- **Example** You could for example use this SPARQL Endpoint URL: http://sparql.wikipathways.org/ and the following SPARQL query, which will select 25 sets of "subject", "predicate" and "object" out of the database, with no filtering at all:: SELECT ?s ?p ?o WHERE { ?s ?p ?o } LIMIT 10 This will generate a 3-column tabular output like this:: <http://identifiers.org/pubmed/12860264> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> <http://identifiers.org/pubmed/15782111> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> <http://identifiers.org/pubmed/11017945> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> <http://identifiers.org/pubmed/10997684> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> <http://identifiers.org/pubmed/19635799> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> <http://identifiers.org/pubmed/16480962> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> <http://identifiers.org/pubmed/15976321> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> <http://identifiers.org/pubmed/17218259> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> <http://identifiers.org/pubmed/17215298> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> <http://identifiers.org/pubmed/11177571> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://vocabularies.wikipathways.org/wp#PublicationReference> </help> </tool>