This HTML5 document contains 37 embedded RDF statements represented using HTML+Microdata notation.

The embedded RDF content will be recognized by any processor of HTML5 Microdata.

PrefixNamespace IRI
n23http://docs.openlinksw.com/virtuoso/sparqlextensions.html#
n14http://vos.openlinksw.com/dataspace/owiki/wiki/VOS/VirtTipsAndTricksGuideAddTriplesNamedGraph/sioc.
dctermshttp://purl.org/dc/terms/
atomhttp://atomowl.org/ontologies/atomrdf#
foafhttp://xmlns.com/foaf/0.1/
n4http://vos.openlinksw.com/dataspace/services/wiki/
oplhttp://www.openlinksw.com/schema/attribution#
n20http://vos.openlinksw.com/wiki/main/VOS/VirtTipsAndTricksGuideAddTriplesNamedGraph/t2.
n2http://vos.openlinksw.com/dataspace/owiki/wiki/VOS/
dchttp://purl.org/dc/elements/1.1/
n12http://vos.openlinksw.com/dataspace/dav#
rdfshttp://www.w3.org/2000/01/rdf-schema#
n3http://rdfs.org/sioc/services#
siocthttp://rdfs.org/sioc/types#
n7http://vos.openlinksw.com/dataspace/person/dav#
n19http://vos.openlinksw.com/wiki/main/VOS/VirtTipsAndTricksGuideAddTriplesNamedGraph/t1.
n10http://vos.openlinksw.com/dataspace/owiki/wiki/
rdfhttp://www.w3.org/1999/02/22-rdf-syntax-ns#
n22http://wikis.openlinksw.com/dataspace/owiki/wiki/OATWikiWeb/
n15http://vos.openlinksw.com/dataspace/owiki#
n18http://ode.openlinksw.
xsdhhttp://www.w3.org/2001/XMLSchema#
n17http://vos.openlinksw.com/dataspace/%28NULL%29/wiki/VOS/
n24http://vos.openlinksw.com/dataspace/person/owiki#
siochttp://rdfs.org/sioc/ns#
Subject Item
n7:this
foaf:made
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph
Subject Item
n12:this
sioc:creator_of
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph
Subject Item
n4:item
n3:services_of
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph
Subject Item
n15:this
sioc:creator_of
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph
Subject Item
n10:VOS
sioc:container_of
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph
atom:entry
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph
atom:contains
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph
Subject Item
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph
rdf:type
atom:Entry sioct:Comment
dcterms:created
2017-06-13T05:36:26.197207
dcterms:modified
2017-06-29T07:41:33.003261
rdfs:label
VirtTipsAndTricksGuideAddTriplesNamedGraph
foaf:maker
n7:this n24:this
dc:title
VirtTipsAndTricksGuideAddTriplesNamedGraph
opl:isDescribedUsing
n14:rdf
sioc:has_creator
n12:this n15:this
sioc:attachment
n19:png n20:png
sioc:content
%META:TOPICPARENT{name="VirtTipsAndTricksGuide"}% ---+How can I use SPARUL to add missing triples to a Named Graph? ---++What? Use of SPARUL to add missing triples to a Named Graph. For example, an ontology/vocabulary extension. ---++Why? A lot of ontologies and vocabularies started life prior to emergence of the Linked Data meme. As a result, many do not include <code>rdfs:isDefinedBy</code> relations (via triples) that associate Classes and Properties in an ontology with the ontology itself, using de-referencable URIs. The downside of this pattern is that Linked Data's follow-your-nose pattern isn't exploitable when viewing these ontologies e.g., when using contemporary Linked Data aware browsers, like the [[http://ode.openlinksw.com][OpenLink Data Explorer]], [[http://wikis.openlinksw.com/dataspace/owiki/wiki/OATWikiWeb/InteractiveSparqlQueryBuilderOverview][OpenLink iSPARQL Query Builder]], [[VirtVisualizeWithPivotViewer][Microsoft Pivot Viewer]] and others. ---++How? If SPARUL privileges are assigned to SPARQL or other accounts associated with SPARQL Endpoint. Or via WebID protected SPARQL endpoint with SPARUL is granted to SPARQL or specific accounts or WebIDs in a group. <verbatim> SPARQL INSERT INTO <LocalNamedGraphIRI> { ?s rdfs:DefinedBy <LocalOntologyEntityURI>. ?o rdfs:isDefinedBy <http://www.w3.org/ns/auth/acl>. } FROM <ExtSourceNamedGraphIRI> WHERE { ?s a ?o } </verbatim> ---+++Example 1 Load Quad Named Graph via Sponger based query: <verbatim> DEFINE get:soft "replace" SELECT DISTINCT * FROM <http://www.w3.org/ns/auth/acl#> WHERE { ?s ?p ?o } </verbatim> %BR%%BR%<img src="%ATTACHURLPATH%/t1.png" style="wikiautogen"/>%BR%%BR% 1 Added Triples via SPARUL to Ontology Named Graph: <verbatim> SPARQL INSERT INTO <http://www.w3.org/ns/auth/acl#> { ?s rdfs:DefinedBy <http://www.w3.org/ns/auth/acl>. ?o rdfs:DefinedBy <http://www.w3.org/ns/auth/acl>. } FROM <http://www.w3.org/ns/auth/acl#> WHERE { ?s a ?o } Query result: callret-0 VARCHAR Insert into <http://www.w3.org/ns/auth/acl#>, 110 (or less) triples -- done No. of rows in result: 1 </verbatim> 1 Via Conductor or Command-line iSQL courtesy of SPASQL execute the following statements: 1 Remove an existing graph: <verbatim> SPARQL CLEAR GRAPH <http://www.w3.org/ns/auth/acl/> ; SPARQL CLEAR GRAPH <http://www.w3.org/ns/auth/acl> ; SPARQL CLEAR GRAPH <http://www.w3.org/ns/auth/acl#> ; Query result: callret-0 ANY Clear <http://www.w3.org/ns/auth/acl/> -- done No. of rows in result: 1 Query result: callret-0 ANY Clear <http://www.w3.org/ns/auth/acl> -- done No. of rows in result: 1 Query result: callret-0 ANY Clear <http://www.w3.org/ns/auth/acl#> -- done No. of rows in result: 1 </verbatim> 1 Load a new graph: <verbatim> SPARQL LOAD <http://www.w3.org/ns/auth/acl> ; Query result: callret-0 VARCHAR Load <http://www.w3.org/ns/auth/acl> into graph <http://www.w3.org/ns/auth/acl> -- done No. of rows in result: 1 </verbatim> 1 Add missing rdfs:isDefinedBy triples via SPARUL: <verbatim> SPARQL INSERT INTO <http://www.w3.org/ns/auth/acl> { ?s rdfs:DefinedBy <http://www.w3.org/ns/auth/acl>. ?o rdfs:DefinedBy <http://www.w3.org/ns/auth/acl>. } FROM <http://www.w3.org/ns/auth/acl> WHERE { ?s a ?o } ; Query result: callret-0 ANY Insert into <http://www.w3.org/ns/auth/acl>, 26 (or less) triples -- done No. of rows in result: 1 </verbatim> 1 Verification: Access the following url: <code><nowiki>http://&lt;cname>/describe/?uri=http://www.w3.org/ns/auth/acl</nowiki></code> %BR%%BR%<img src="%ATTACHURLPATH%/t2.png" style="wikiautogen"/>%BR%%BR% ---+++Related * [[VirtTipsAndTricksGuide][Virtuoso Tips and Tricks Collection]] * [[http://docs.openlinksw.com/virtuoso/sparqlextensions.html#rdfsparul][SPARUL -- an Update Language For RDF Graphs]] * [[VirtSponger][Virtuoso Sponger]] * [[http://ode.openlinksw.com][OpenLink Data Explorer]] * [[http://wikis.openlinksw.com/dataspace/owiki/wiki/OATWikiWeb/InteractiveSparqlQueryBuilderOverview][OpenLink iSPARQL Query Builder]] * [[VirtVisualizeWithPivotViewer][Microsoft Pivot Viewer]]
sioc:id
dccc4536f738f2a3521a6de5cbe92e7d
sioc:link
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph
sioc:has_container
n10:VOS
n3:has_services
n4:item
atom:title
VirtTipsAndTricksGuideAddTriplesNamedGraph
sioc:links_to
n17:WebIDs n18:com n17:WebID n22:InteractiveSparqlQueryBuilderOverview n23:rdfsparul
atom:source
n10:VOS
atom:author
n7:this
atom:published
2017-06-13T05:36:26Z
atom:updated
2017-06-29T07:41:33Z
sioc:topic
n10:VOS
Subject Item
n2:VirtSponger
sioc:links_to
n2:VirtTipsAndTricksGuideAddTriplesNamedGraph