193_book_citation_bibliographic_record

rq turtle/ttl

Find the full bibliographic record of a book chapter cited as evidence for a protein annotation: title, authors, editors, publisher, place and pages — distinct from the PubMed-ID-focused journal citation example (#19)

Use at

PREFIX up: <http://purl.uniprot.org/core/>
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#>

SELECT
  ?protein
  ?citation
  ?title
  (GROUP_CONCAT(DISTINCT ?author; separator=", ") AS ?authors)
  (GROUP_CONCAT(DISTINCT ?editor; separator=", ") AS ?editors)
  (SAMPLE(?publisher) AS ?onePublisher)
  (SAMPLE(?place) AS ?onePlace)
  (SAMPLE(?pages) AS ?onePages)
WHERE {
  ?protein a up:Protein ;
    up:annotation ?annotation .
  ?linkToEvidence rdf:object ?annotation ;
    up:attribution ?attribution .
  ?attribution up:source ?citation .
  ?citation a up:Book_Citation ;
    up:title ?title ;
    up:author ?author ;
    up:pages ?pages .
  OPTIONAL { ?citation up:editor ?editor }
  OPTIONAL { ?citation up:publisher ?publisher }
  OPTIONAL { ?citation up:place ?place }
}
GROUP BY ?protein ?citation ?title
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
  v2("?annotation")
  v4("?attribution")
  v7("?author"):::projected 
  v12("?authors")
  v5("?citation"):::projected 
  v9("?editor"):::projected 
  v13("?editors")
  v3("?linkToEvidence")
  v16("?onePages")
  v15("?onePlace")
  v14("?onePublisher")
  v8("?pages"):::projected 
  v11("?place"):::projected 
  v1("?protein"):::projected 
  v10("?publisher"):::projected 
  v6("?title"):::projected 
  c7(["up:Book_Citation"]):::iri 
  c2(["up:Protein"]):::iri 
  v1 --"a"-->  c2
  v1 --"up:annotation"-->  v2
  v3 --"rdf:object"-->  v2
  v3 --"up:attribution"-->  v4
  v4 --"up:source"-->  v5
  v5 --"a"-->  c7
  v5 --"up:title"-->  v6
  v5 --"up:author"-->  v7
  v5 --"up:pages"-->  v8
  subgraph optional0["(optional)"]
  style optional0 fill:#bbf,stroke-dasharray: 5 5;
    v5 -."up:editor".->  v9
  end
  subgraph optional1["(optional)"]
  style optional1 fill:#bbf,stroke-dasharray: 5 5;
    v5 -."up:publisher".->  v10
  end
  subgraph optional2["(optional)"]
  style optional2 fill:#bbf,stroke-dasharray: 5 5;
    v5 -."up:place".->  v11
  end
  bind5[/"?author"/]
  v7 --o bind5
  bind5 --as--o v12
  bind6[/"?editor"/]
  v9 --o bind6
  bind6 --as--o v13
  bind7[/"sample(?publisher)"/]
  v10 --o bind7
  bind7 --as--o v14
  bind8[/"sample(?place)"/]
  v11 --o bind8
  bind8 --as--o v15
  bind9[/"sample(?pages)"/]
  v8 --o bind9
  bind9 --as--o v16