query-4f314d73d0efca360cb61efdf0e7dd33

rq turtle/ttl

TODO

Use at

PREFIX wikibase: <http://wikiba.se/ontology#>
PREFIX wdt: <http://www.wikidata.org/prop/direct/>
PREFIX bd: <http://www.bigdata.com/rdf#>
SELECT ?item ?itemLabel ?PMID ?authorLabel ?author1 ?orcid where
{
  { {
  select ?item ?PMID ?author ?orcid ?author1 WHERE 
{
  ?item wdt:P698 ?PMID . # has PubMed-ID
  VALUES ?PMID { '28665778' }
  ?item wdt:P50 ?author .
  optional {?author wdt:P496 ?orcid .} 
} }}
  UNION
  { {
    select ?item ?PMID ?author ?author1 WHERE 
{
  ?item wdt:P698 ?PMID . # has PubMed-ID
  VALUES ?PMID { '28665778' }
  ?item wdt:P2093 ?author1 .
} }}
  SERVICE wikibase:label { bd:serviceParam wikibase:language "[AUTO_LANGUAGE],en" .}
  }

Query found at

graph TD classDef projected fill:lightgreen; classDef literal fill:orange; classDef iri fill:yellow; v5("?PMID"):::projected v3("?author") v5("?author1"):::projected v1("?item"):::projected v4("?orcid"):::projected c6(["bd:serviceParam"]):::iri c8(["#91;AUTO_LANGUAGE#93;,en"]):::literal subgraph union0[" Union "] subgraph union0l[" "] style union0l fill:#abf,stroke-dasharray: 3 3; v1 --"wdt:P698"--> v5 bind0[/VALUES ?PMID/] bind0-->v5 bind00(["28665778"]) bind00 --> bind0 v1 --"wdt:P2093"--> v5 end subgraph union0r[" "] style union0r fill:#abf,stroke-dasharray: 3 3; v1 --"wdt:P698"--> v5 bind1[/VALUES ?PMID/] bind1-->v5 bind10(["28665778"]) bind10 --> bind1 v1 --"wdt:P50"--> v3 subgraph optional0["(optional)"] style optional0 fill:#bbf,stroke-dasharray: 5 5; v3 -."wdt:P496".-> v4 end end union0r <== or ==> union0l end subgraph s1["http://wikiba.se/ontology#label"] style s1 stroke-width:4px; c6 --"wikibase:language"--> c8 end