A set of SPARQL examples that are used in different SIB resources
List all UniProtKB proteins and the diseases are annotated to be related.
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