query-1de66b4f25c3724209810aa61ee1a25c

rq turtle/ttl

TODO

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX wd: <http://www.wikidata.org/entity/>
PREFIX schema: <http://schema.org/>
PREFIX ps: <http://www.wikidata.org/prop/statement/>
PREFIX pq: <http://www.wikidata.org/prop/qualifier/>
PREFIX p: <http://www.wikidata.org/prop/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?itemLabel ?givennameLabel ?series2 ?familynameLabel ?series ?article
WHERE 
{
  ?article schema:about ?item ;
          schema:isPartOf <https://pt.wikisource.org/> .
  OPTIONAL {?item p:P734 ?stat . ?stat ps:P734 ?familyname .
           OPTIONAL {?stat pq:P1545 ?series . } }
  OPTIONAL {?item p:P735 ?stat2 . ?stat2 ps:P735 ?givenname .
           OPTIONAL {?stat2 pq:P1545 ?series2 .} }
  ?item wdt:P31 wd:Q5 .
  SERVICE wikibase:label { bd:serviceParam wikibase:language "pt,en". }
}

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v1("?article"):::projected v4("?familyname") v7("?givenname") v2("?item"):::projected v5("?series"):::projected v8("?series2"):::projected v3("?stat") v6("?stat2") c14(["pt,en"]):::literal c12(["bd:serviceParam"]):::iri c3([https://pt.wikisource.org/]):::iri c10(["wd:Q5"]):::iri v1 --"schema:about"--> v2 v1 --"schema:isPartOf"--> c3 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:P734".-> v3 v3 --"p:statement/P734"--> v4 subgraph optional1["(optional)"] style optional1 fill:#bbf,stroke-dasharray: 5 5; v3 -."p:qualifier/P1545".-> v5 end end subgraph optional2["(optional)"] style optional2 fill:#bbf,stroke-dasharray: 5 5; v2 -."p:P735".-> v6 v6 --"p:statement/P735"--> v7 subgraph optional3["(optional)"] style optional3 fill:#bbf,stroke-dasharray: 5 5; v6 -."p:qualifier/P1545".-> v8 end end v2 --"p:direct/P31"--> c10 subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c12 --"wikibase:language"--> c14 end