SPARQL Examples: Difference between revisions
Jump to navigation
Jump to search
(Blanked the page) Tags: Blanking Manual revert |
No edit summary |
||
Line 1: | Line 1: | ||
== All persons with all properties == | |||
<sparql tryit="1"> | |||
PREFIX rlwd: <https://riga-literata.wikibase.cloud/entity/> | |||
PREFIX rlwdt: <https://riga-literata.wikibase.cloud/prop/direct/> | |||
SELECT ?person ?personLabel ?genderLabel ?birthdate ?birthplaceLabel ?deathdate ?deathplaceLabel ?qid ?viaf ?lnc10 | |||
WHERE | |||
{ | |||
?person rlwdt:P1 rlwd:Q6. | |||
OPTIONAL { ?person rlwdt:P15 ?gender.} | |||
OPTIONAL { ?person rlwdt:P18 ?birthdate.} | |||
OPTIONAL { ?person rlwdt:P20 ?birthplace.} | |||
OPTIONAL { ?person rlwdt:P19 ?deathdate.} | |||
OPTIONAL { ?person rlwdt:P21 ?deathplace.} | |||
OPTIONAL { ?person rlwdt:P6 ?qid.} | |||
OPTIONAL { ?person rlwdt:P30 ?viaf.} | |||
OPTIONAL { ?person rlwdt:P4 ?lnc10.} | |||
SERVICE wikibase:label { bd:serviceParam wikibase:language "en,[AUTO_LANGUAGE]". } | |||
} | |||
</sparql> |
Revision as of 14:48, 17 January 2023
All persons with all properties
PREFIX rlwd: <https://riga-literata.wikibase.cloud/entity/>
PREFIX rlwdt: <https://riga-literata.wikibase.cloud/prop/direct/>
SELECT ?person ?personLabel ?genderLabel ?birthdate ?birthplaceLabel ?deathdate ?deathplaceLabel ?qid ?viaf ?lnc10
WHERE
{
?person rlwdt:P1 rlwd:Q6.
OPTIONAL { ?person rlwdt:P15 ?gender.}
OPTIONAL { ?person rlwdt:P18 ?birthdate.}
OPTIONAL { ?person rlwdt:P20 ?birthplace.}
OPTIONAL { ?person rlwdt:P19 ?deathdate.}
OPTIONAL { ?person rlwdt:P21 ?deathplace.}
OPTIONAL { ?person rlwdt:P6 ?qid.}
OPTIONAL { ?person rlwdt:P30 ?viaf.}
OPTIONAL { ?person rlwdt:P4 ?lnc10.}
SERVICE wikibase:label { bd:serviceParam wikibase:language "en,[AUTO_LANGUAGE]". }
}