sparql-examples

A set of SPARQL examples that are used in different SIB resources

View the Project on GitHub sib-swiss/sparql-examples

121_proteins_and_diseases_linked

rq turtle/ttl

List all UniProtKB proteins and the diseases are annotated to be related.

Use at


PREFIX up: <http://purl.uniprot.org/core/>

SELECT
	?protein
	?disease
WHERE {
	?protein a up:Protein ;
    	up:annotation ?annotation .
	?annotation a up:Disease_Annotation ;
    	up:disease ?disease .
	?disease a up:Disease .
}
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
  v2("?annotation")
  v3("?disease"):::projected 
  v1("?protein"):::projected 
  c6(["up:Disease"]):::iri 
  c4(["up:Disease_Annotation"]):::iri 
  c2(["up:Protein"]):::iri 
  v1 --"a"-->  c2
  v1 --"up:annotation"-->  v2
  v2 --"a"-->  c4
  v2 --"up:disease"-->  v3
  v3 --"a"-->  c6