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

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

PrefixNamespace IRI
dctermshttp://purl.org/dc/terms/
atomhttp://atomowl.org/ontologies/atomrdf#
foafhttp://xmlns.com/foaf/0.1/
n15http://vos.openlinksw.com/dataspace/services/wiki/
oplhttp://www.openlinksw.com/schema/attribution#
n2http://vos.openlinksw.com/dataspace/owiki/wiki/VOS/
dchttp://purl.org/dc/elements/1.1/
n6http://vos.openlinksw.com/dataspace/dav#
rdfshttp://www.w3.org/2000/01/rdf-schema#
n16http://rdfs.org/sioc/services#
siocthttp://rdfs.org/sioc/types#
n4http://vos.openlinksw.com/dataspace/person/dav#
n21http://lod.openlinksw.com/sparql?default-graph-uri=&query=CONSTRUCT+%0D%0A++%7B%0D%0A++++%3Fcategory++a+++++++++++++++++++++++++++++++++++++++++++++++++++++%3Chttp%3A%2F%2Fwww.w3.org%2F2004%2F02%2Fskos%2Fcore%23Concept%3E+.%0D%0A++++%3Fcategory++%3Chttp%3A%2F%2Fwww.turnguard.com%2Fvirtuoso%2Faggregates%23count%3E++%3Fcount%0D%0A++%7D%0D%0AWHERE+%0D%0A++%7B%0D%0A++++%7B+%0D%0A++++++SELECT+++++++++++++DISTINCT+%3Fcategory+%0D%0A++++++++++++++COUNT%28%3Fcategory%29+AS+%3Fcount%0D%0A++++++WHERE%0D%0A++++++++%7B%0D%0A++++++++++%3Fs+++%3Chttp%3A%2F%2Fpurl.org%2Fdc%2Fterms%2Fsubject%3E+%3Fcategory%0D%0A++++++++++FILTER+%28%0D%0A+++++++++++++++++++%3Fs++%3D%3Chttp%3A%2F%2Fdbpedia.org%2Fresource%2FHiggs_boson%3E+%0D%0A+++++++++++++++++++||+%0D%0A+++++++++++++++++++%3Fs++%3D%3Chttp%3A%2F%2Fdbpedia.org%2Fresource%2FGluon%3E%0D%0A+++++++++++++++++%29%0D%0A++++++++%7D+%0D%0A++++%7D+%0D%0A++%7D&should-sponge=&format=application%2Frdf%2Bxml&CXML_redir_for_subjs=121&CXML_redir_for_hrefs=&timeout=15000&debug=
n11http://vos.openlinksw.com/dataspace/owiki/wiki/
n19http://vos.openlinksw.com/dataspace/owiki/wiki/VOS/VirtTipsAndTricksGuideConstructAggregateFunctions/sioc.
rdfhttp://www.w3.org/1999/02/22-rdf-syntax-ns#
n10http://vos.openlinksw.com/dataspace/owiki#
n9http://lod.openlinksw.
xsdhhttp://www.w3.org/2001/XMLSchema#
n17http://vos.openlinksw.com/dataspace/%28NULL%29/wiki/VOS/
n8http://vos.openlinksw.com/dataspace/person/owiki#
siochttp://rdfs.org/sioc/ns#
Subject Item
n4:this
foaf:made
n2:VirtTipsAndTricksGuideConstructAggregateFunctions
Subject Item
n6:this
sioc:creator_of
n2:VirtTipsAndTricksGuideConstructAggregateFunctions
Subject Item
n15:item
n16:services_of
n2:VirtTipsAndTricksGuideConstructAggregateFunctions
Subject Item
n10:this
sioc:creator_of
n2:VirtTipsAndTricksGuideConstructAggregateFunctions
Subject Item
n11:VOS
sioc:container_of
n2:VirtTipsAndTricksGuideConstructAggregateFunctions
atom:entry
n2:VirtTipsAndTricksGuideConstructAggregateFunctions
atom:contains
n2:VirtTipsAndTricksGuideConstructAggregateFunctions
Subject Item
n2:VirtTipsAndTricksGuideConstructAggregateFunctions
rdf:type
atom:Entry sioct:Comment
dcterms:created
2017-06-13T05:38:31.912016
dcterms:modified
2017-06-13T05:38:31.912016
rdfs:label
VirtTipsAndTricksGuideConstructAggregateFunctions
foaf:maker
n8:this n4:this
dc:title
VirtTipsAndTricksGuideConstructAggregateFunctions
opl:isDescribedUsing
n19:rdf
sioc:has_creator
n6:this n10:this
sioc:content
%META:TOPICPARENT{name="VirtTipsAndTricksGuide"}% ---+ How can I include aggregate function values as objects in <code>SPARQL CONSTRUCT</code> queries? For a <code>CONSTRUCT</code> query, the aggregate function must be called as part of a subquery in the <code>CONSTRUCT</code>'s <code>WHERE</code> clause. For example, starting with this SPARQL <code>SELECT</code> query -- <verbatim> SELECT DISTINCT ?category COUNT(?category) AS ?count WHERE { ?s <http://purl.org/dc/terms/subject> ?category FILTER ( ?s =<http://dbpedia.org/resource/Higgs_boson> || ?s =<http://dbpedia.org/resource/Gluon> ) } </verbatim> The <code>CONSTRUCT</code> query would be -- <verbatim> CONSTRUCT { ?category a <http://www.w3.org/2004/02/skos/core#Concept> . ?category <http://www.turnguard.com/virtuoso/aggregates#count> ?count } WHERE { { SELECT DISTINCT ?category COUNT(?category) AS ?count WHERE { ?s <http://purl.org/dc/terms/subject> ?category FILTER ( ?s =<http://dbpedia.org/resource/Higgs_boson> || ?s =<http://dbpedia.org/resource/Gluon> ) } } } </verbatim> [[http://lod.openlinksw.com/sparql?default-graph-uri=&query=CONSTRUCT+%0D%0A++%7B%0D%0A++++%3Fcategory++a+++++++++++++++++++++++++++++++++++++++++++++++++++++%3Chttp%3A%2F%2Fwww.w3.org%2F2004%2F02%2Fskos%2Fcore%23Concept%3E+.%0D%0A++++%3Fcategory++%3Chttp%3A%2F%2Fwww.turnguard.com%2Fvirtuoso%2Faggregates%23count%3E++%3Fcount%0D%0A++%7D%0D%0AWHERE+%0D%0A++%7B%0D%0A++++%7B+%0D%0A++++++SELECT+++++++++++++DISTINCT+%3Fcategory+%0D%0A++++++++++++++COUNT%28%3Fcategory%29+AS+%3Fcount%0D%0A++++++WHERE%0D%0A++++++++%7B%0D%0A++++++++++%3Fs+++%3Chttp%3A%2F%2Fpurl.org%2Fdc%2Fterms%2Fsubject%3E+%3Fcategory%0D%0A++++++++++FILTER+%28%0D%0A+++++++++++++++++++%3Fs++%3D%3Chttp%3A%2F%2Fdbpedia.org%2Fresource%2FHiggs_boson%3E+%0D%0A+++++++++++++++++++||+%0D%0A+++++++++++++++++++%3Fs++%3D%3Chttp%3A%2F%2Fdbpedia.org%2Fresource%2FGluon%3E%0D%0A+++++++++++++++++%29%0D%0A++++++++%7D+%0D%0A++++%7D+%0D%0A++%7D&should-sponge=&format=application%2Frdf%2Bxml&CXML_redir_for_subjs=121&CXML_redir_for_hrefs=&timeout=15000&debug=on][View the results]] of the query execution on the [[http://lod.openlinksw.com][LOD]] instance. ---++Related * [[VirtTipsAndTricksGuide][Virtuoso Tips and Tricks Collection]]
sioc:id
9e339f9bd453dc145dc3f2944d36e523
sioc:link
n2:VirtTipsAndTricksGuideConstructAggregateFunctions
sioc:has_container
n11:VOS
n16:has_services
n15:item
atom:title
VirtTipsAndTricksGuideConstructAggregateFunctions
sioc:links_to
n9:com n17:VirtTipsAndTricksGuide n21:on
atom:source
n11:VOS
atom:author
n4:this
atom:published
2017-06-13T05:38:31Z
atom:updated
2017-06-13T05:38:31Z
sioc:topic
n11:VOS