query-2e754601daa71fc2de5679ed006cde51
Participants in a battle. Which ships participated? (Q373401)Battle of Cape St. Vincent Consider a battle such as provides a list of 15 + 7 ships on the British side. Spanish fleet is broken down by squadrons. en:Battle_of_Cape_St.Vincent(1797) (Q213958)HMS Victory Consider → Battle of Trafalgar, Battle of Cape St. Vincent(P1344)participant in conflict is used for battles... → First Battle of Ushant, Battle of Ushant, Battle of Cape Spartel, Battle of Cape St. Vincent, Battle of Trafalgar (P607)conflict The query now gets 19 results (short of 22). Three ships are unrated.
Use at
- https://query.wikidata.org/sparql
PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?ship ?shipLabel WHERE {
# ship of the line Q207452
?ship wdt:P31/wdt:P279 wd:Q207452 .
# conflict
?ship wdt:P607 wd:Q373401 .
# particpant
# ?ship wdt:P1344 wd:Q373401 .
SERVICE wikibase:label {
bd:serviceParam wikibase:language "en" .
}
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v1("?ship"):::projected
a1((" "))
c3(["wd:Q207452"]):::iri
c7(["bd:serviceParam"]):::iri
c5(["wd:Q373401"]):::iri
c9(["en"]):::literal
v1 --"wdt:P31"--> a1
a1 --"wdt:P279"--> c3
v1 --"wdt:P607"--> c5
subgraph s1["http://wikiba.se/ontology#label"]
style s1 stroke-width:4px;
c7 --"wikibase:language"--> c9
end