A set of SPARQL examples that are used in different SIB resources
Translate a selection of UniProtKB accession numbers into other options using the identifiers.org translating endpoint.
PREFIX owl: <http://www.w3.org/2002/07/owl#>
PREFIX uniprotkb: <http://purl.uniprot.org/uniprot/>
PREFIX up: <http://purl.uniprot.org/core/>
SELECT
?protein
?otherIdentifier
WHERE {
VALUES (?protein) {(uniprotkb:P00750) (uniprotkb:P05067)}
?protein a up:Protein .
SERVICE <https://sparql.api.identifiers.org/sparql> {
?protein owl:sameAs ?otherIdentifier .
}
}
graph TD
classDef projected fill:lightgreen;
classDef literal fill:orange;
classDef iri fill:yellow;
v2("?otherIdentifier"):::projected
v1("?protein"):::projected
c2(["up:Protein"]):::iri
bind0[/VALUES ?protein/]
bind0-->v1
bind00(["uniprotkb:P00750"])
bind00 --> bind0
bind01(["uniprotkb:P05067"])
bind01 --> bind0
v1 --"a"--> c2
subgraph s1["https://sparql.api.identifiers.org/sparql"]
style s1 stroke-width:4px;
v1 --"owl:sameAs"--> v2
end