'How to iterate a query over the whole db in SPARQL?
i'm not new to SQL, but new to SPARQL and i need to pull some information from the ULAN database (https://www.getty.edu/research/tools/vocabularies/ulan/)
The infos that i need are correctly pulled for 1 author (id: 500115493) using this query that i've found on the FAQ section:
select * {
ulan:500115493 ?rel ?x.
?rel sesame:directSubPropertyOf skos:related.
?x gvp:prefLabelGVP/xl:literalForm ?name.
?x foaf:focus/gvp:biographyPreferred/schema:description ?bio.
optional {[
rdf:subject ulan:500115493;
rdf:predicate ?rel;
rdf:object ?x;
rdfs:comment ?comment]}}
Those are the relationship infos about A. Dürer.
Now, i need to generalize the query and make it work for all the authors on the db in such a way that the output has this kind of structure:
{'name_of_the_author': [data]}
where "data" are the informations pulled by the example query, does not matter how formatted.
How can i structure such a query?
Thanks in advance, Alessandro
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|