Skip to content

Instantly share code, notes, and snippets.

View crssnky's full-sized avatar
🏍️
ブンブン

crssnky crssnky

🏍️
ブンブン
View GitHub Profile
PREFIX schema: <http://schema.org/>
SELECT ?name ?BMI1 ?BMI2 ?diff2
WHERE {
?s schema:name|schema:alternateName ?name;
schema:height ?height;
schema:weight ?weight.
bind((自分の身長)as ?myHeight).
bind((自分の体重)as ?myWeight).
bind((?weight/(?height*?height*0.01*0.01))as ?BMI1)
PREFIX imas: <https://sparql.crssnky.xyz/imasrdf/URIs/imas-schema.ttl#>
SELECT distinct ?ss ?cv
WHERE {
?s imas:cv ?cv.
service <http://ja.dbpedia.org/sparql>{
?ss ?a ?cv.
bind(concat("http://ja.dbpedia.org/resource/",str(?cv))as ?cvs)
filter(str(?ss)=?cvs)
}
PREFIX schema: <http://schema.org/>
PREFIX math: <http://www.w3.org/2005/xpath-functions/math#>
SELECT ?名前 (?height as ?身長) (?weight as ?体重) ?デュポア式 ?新谷式 ?藤本式
WHERE {
?s schema:name ?名前;
schema:height ?height;
schema:weight ?weight;
bind(math:pow(?height,0.725)*math:pow(?weight,0.425)*0.007184 as ?デュポア式)
bind(math:pow(?height,0.725)*math:pow(?weight,0.425)*0.007358 as ?新谷式)
PREFIX schema: <http://schema.org/>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX imas: <https://sparql.crssnky.xyz/imasrdf/URIs/imas-schema.ttl#>
SELECT ?calling ?called
WHERE {
?s rdf:type imas:CallName;
imas:Source ?caller;
imas:Destination ?callee;
imas:Called ?called.
PREFIX imas: <https://sparql.crssnky.xyz/imasrdf/URIs/imas-schema.ttl#>
PREFIX schema: <http://schema.org/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT (SUM(?得票数) as ?総得票数) (Sample(?nm) as ?名前)
WHERE {
?s schema:member ?o;
imas:VoteNumber ?得票数.
?o rdfs:label ?nm
}group by(?o) order by(?総得票数)
PREFIX schema: <http://schema.org/>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX imas: <https://sparql.crssnky.xyz/imasrdf/URIs/imas-schema.ttl#>
SELECT *
WHERE {
?s rdf:type imas:ScriptText;
imas:Source ?source;
schema:text ?text.
?source schema:name ?name;
PREFIX schema: <http://schema.org/>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX imas: <https://sparql.crssnky.xyz/imasrdf/URIs/imas-schema.ttl#>
SELECT (count(?name)as ?回数) (sample(?name)as ?楽曲名)
WHERE {
?s rdf:type imas:SetlistNumber;
schema:name ?name;
}group by ?name having(?回数>4) order by DESC(?回数)
PREFIX schema: <http://schema.org/>
PREFIX imas: <https://sparql.crssnky.xyz/imasrdf/URIs/imas-schema.ttl#>
select ?利き手 ?名前
where{
?s schema:name|schema:alternateName ?name;
imas:Handedness ?利き手;
filter(regex(str(?name), "まゆ")).
?idol imas:Handedness ?利き手;
schema:name ?名前.
}
PREFIX schema: <http://schema.org/>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>
PREFIX imas: <https://sparql.crssnky.xyz/imasrdf/URIs/imas-schema.ttl#>
SELECT ?ユニット名 (avg(?h) as ?平均身長)
WHERE {
?s rdf:type imas:Unit;
schema:name ?ユニット名;
schema:member ?m.
?m schema:height ?h.
}group by(?ユニット名) order by desc(?平均身長)
PREFIX schema: <http://schema.org/>
PREFIX imas: <https://sparql.crssnky.xyz/imasrdf/URIs/imas-schema.ttl#>
SELECT ?o ?h
WHERE {
?s schema:name|schema:alternateName ?o;
schema:height ?h.
}order by(?h)