Skip to content

Instantly share code, notes, and snippets.

@adorsk-whoi
adorsk-whoi / sparql_multiple_facets_one_query.sparql
Created June 17, 2011 13:39
SPARQL: Multiple facets in one query
# This SPARQL query could be used to calculate facets for SPARQL result set.
# The base result is defined as a subquery.
# Facets are calculated for the result set, and are returned as rows consisting of a facet id, a label,
# and a count.
# This query works against Virtuoso SPARQL endpoints.
# You can try it the against dbpedia virtuoso sparql endpoint, but it will probably fail due to the DBPedia endpoint's
# performance limitations.
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
@adorsk-whoi
adorsk-whoi / gist:1080298
Created July 13, 2011 13:37
ohai user_public_keys plugin
provides 'user_public_keys'
require 'etc'
# Initialize mash.
user_public_keys Mash.new
# For each entry in the password file...
Etc.passwd do |entry|