query-022f44b119e579fbe7ea7c700f74907b
Propertiesauthor (P50)publication date (P577)first line (P1922)
Use at
- https://query.wikidata.org/sparql
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>
SELECT ?work ?title ?firstline ?year ?enws ?enwp WHERE {
?work wdt:P50 wd:Q5460603
OPTIONAL{?work wdt:P577 ?pubdate}
OPTIONAL{?work wdt:P1922 ?firstline}
BIND(YEAR(?pubdate) as ?year)
OPTIONAL{ ?enws schema:about ?work ; schema:isPartOf <https://en.wikisource.org/> }
OPTIONAL{ ?enwp schema:about ?work ; schema:isPartOf <https://en.wikipedia.org/> }
OPTIONAL{ ?work rdfs:label ?title filter(lang(?title) = "en") }
}
Query found at
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v7("?enwp"):::projected
v6("?enws"):::projected
v4("?firstline"):::projected
v3("?pubdate")
v1("?title"):::projected
v2("?work"):::projected
v5("?year"):::projected
c9([https://en.wikipedia.org/]):::iri
c8([https://en.wikisource.org/]):::iri
c3(["wd:Q5460603"]):::iri
v2 --"wdt:P50"--> c3
subgraph optional0["(optional)"]
style optional0 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wdt:P577".-> v3
end
subgraph optional1["(optional)"]
style optional1 fill:#bbf,stroke-dasharray: 5 5;
v2 -."wdt:P1922".-> v4
end
bind0[/"year-from-dateTime(?pubdate)"/]
v3 --o bind0
bind0 --as--o v5
subgraph optional2["(optional)"]
style optional2 fill:#bbf,stroke-dasharray: 5 5;
v6 -."schema:about".-> v2
v6 --"schema:isPartOf"--> c8
end
subgraph optional3["(optional)"]
style optional3 fill:#bbf,stroke-dasharray: 5 5;
v7 -."schema:about".-> v2
v7 --"schema:isPartOf"--> c9
end
subgraph optional4["(optional)"]
style optional4 fill:#bbf,stroke-dasharray: 5 5;
v2 -."rdfs:label".-> v1
end