Last active
December 1, 2019 08:12
-
-
Save foooomio/8314036fee8bc74c8d7da835ab1b7fa3 to your computer and use it in GitHub Desktop.
ピコピコプラネットのクエリ例
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Turtle 形式で出力させるのが見やすくておすすめです | |
BASE <https://mltd.pikopikopla.net/resource/> | |
DESCRIBE <LTP_01> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BASE <https://mltd.pikopikopla.net/resource/> | |
PREFIX : <http://schema.org/> | |
SELECT ?album ?artist ?position | |
WHERE { | |
?s a :MusicAlbum ; | |
:name ?album ; | |
:track [ | |
:recordingOf/:name "Thank You!" ; | |
:byArtist/:name ?artist ; | |
:position ?position | |
] . | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BASE <https://mltd.pikopikopla.net/resource/> | |
PREFIX mltd: <https://mltd.pikopikopla.net/mltd-schema#> | |
PREFIX : <http://schema.org/> | |
PREFIX foaf: <http://xmlns.com/foaf/0.1/> | |
SELECT ?name ?account ?url | |
WHERE { | |
?s a mltd:VoiceActor ; | |
:name ?name ; | |
foaf:account [ | |
foaf:name "Twitter" ; | |
foaf:accountName ?account ; | |
foaf:page ?url | |
] . | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BASE <https://mltd.pikopikopla.net/resource/> | |
PREFIX mltd: <https://mltd.pikopikopla.net/mltd-schema#> | |
PREFIX : <http://schema.org/> | |
SELECT ?agency (COUNT(?agency) AS ?people) | |
WHERE { | |
?s a mltd:VoiceActor ; | |
:memberOf ?agency . | |
} | |
GROUP BY ?agency | |
ORDER BY DESC(?people) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BASE <https://mltd.pikopikopla.net/resource/> | |
PREFIX : <http://schema.org/> | |
SELECT DISTINCT ?album ?unit_name (GROUP_CONCAT(?member;separator=",") AS ?members) | |
WHERE { | |
?unit a :MusicGroup ; | |
:member/:name ?member ; | |
^:byArtist/^:track/:name ?album . | |
OPTIONAL { ?unit :name ?unit_name } | |
} | |
GROUP BY ?unit ?unit_name ?album |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BASE <https://mltd.pikopikopla.net/resource/> | |
PREFIX mltd: <https://mltd.pikopikopla.net/mltd-schema#> | |
PREFIX : <http://schema.org/> | |
SELECT ?album ?position ?song | |
WHERE { | |
?s a :MusicAlbum ; | |
:name ?album ; | |
:track [ | |
:recordingOf/:name ?song ; | |
:byArtist/:member?/:name "七尾百合子" ; | |
:position ?position | |
] . | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BASE <https://mltd.pikopikopla.net/resource/> | |
PREFIX : <http://schema.org/> | |
SELECT ?song (COUNT(?song) AS ?count) | |
WHERE { | |
?s a :MusicAlbum ; | |
:name ?album ; | |
:track [ | |
:recordingOf/:name ?song ; | |
:byArtist/:name ?artist | |
] . | |
} | |
GROUP BY ?song | |
ORDER BY DESC(?count) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BASE <https://mltd.pikopikopla.net/resource/> | |
PREFIX mltd: <https://mltd.pikopikopla.net/mltd-schema#> | |
PREFIX : <http://schema.org/> | |
SELECT (STR(?givenName) AS ?名前) (COUNT(?s) AS ?人数) (GROUP_CONCAT(?name) AS ?該当者) | |
WHERE { | |
?s a mltd:VoiceActor ; | |
:name ?name ; | |
:givenName ?givenName . | |
FILTER(LANG(?givenName) = 'ja-hira') | |
} | |
GROUP BY ?givenName | |
HAVING (?人数 >= 2) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment