bio-ontology-research-group / aberowlweb

Other
3 stars 1 forks source link

SPARQL endpoint always returns "Invalid Sparql query" #120

Open jpmccu opened 2 years ago

jpmccu commented 2 years ago

This is the case for even simple queries like:

SELECT DISTINCT ?p where {?s ?p ?o.}

and

prefix owl: <http://www.w3.org/2002/07/owl#> 

SELECT distinct ?ontology
WHERE {
    ?ontology a owl:Ontology.
}
JervenBolleman commented 2 years ago

I unfortunately have the same problem.

coolmaksat commented 2 years ago

Hi, let me check this, I will get back to you soon

coolmaksat commented 2 years ago

I think this is not working because we do not have sparql endpoint there. This service is for expanding a sparql query with the information stored in the ontologies and you need to specify the sparql endpoint in the query. For example:

PREFIX rdfs: http://www.w3.org/2000/01/rdf-schema#
PREFIX rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns#
PREFIX obo: http://purl.obolibrary.org/obo/
SELECT ?procedure ?evidenceCode ?phenotypeCorrected
FROM http://ddiem.phenomebrowser.net
WHERE {
VALUES ?procedureType {
OWL equivalent http://ddiem.phenomebrowser.net/sparql {
'metabolite replacement'
}
} .
?procedure rdf:type ?procedureType .
?procedure obo:RO_0002558 ?evidenceCode .
?procedure obo:RO_0002212 ?phenotypes .
?phenotypes rdfs:label ?phenotypeCorrected .
}

jpmccu commented 2 years ago

That's not at all clear from the documentation, and is pretty unusual.

On Mon, Jun 20, 2022 at 8:29 AM Maxat Kulmanov @.***> wrote:

I think this is not working because we do not have sparql endpoint there. This service is for expanding a sparql query with the information stored in the ontologies and you need to specify the sparql endpoint in the query. For example:

PREFIX rdfs: http://www.w3.org/2000/01/rdf-schema# PREFIX rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns# PREFIX obo: http://purl.obolibrary.org/obo/ SELECT ?procedure ?evidenceCode ?phenotypeCorrected FROM http://ddiem.phenomebrowser.net http://ddiem.phenomebrowser.net WHERE { VALUES ?procedureType { OWL equivalent http://ddiem.phenomebrowser.net/sparql { 'metabolite replacement' } } . ?procedure rdf:type ?procedureType . ?procedure obo:RO_0002558 ?evidenceCode . ?procedure obo:RO_0002212 ?phenotypes . ?phenotypes rdfs:label ?phenotypeCorrected . }

— Reply to this email directly, view it on GitHub https://github.com/bio-ontology-research-group/aberowlweb/issues/120#issuecomment-1160388150, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAETCEILSPFWFBF3HMZHVALVQBPZFANCNFSM5OUZHKFA . You are receiving this because you authored the thread.Message ID: @.***>

-- Jamie McCusker (she/her/hers)

Director, Data Operations Tetherless World Constellation Rensselaer Polytechnic Institute @. @.> http://tw.rpi.edu

leechuck commented 2 years ago

Hello,

AberOWL does SPARQL query rewriting but does not provide its own SPARQL endpoint (see the original paper, https://link.springer.com/article/10.1186/s12859-015-0456-9).

But you are right that this is not particularly useful; we will add this as enhancement to put in the next release.

jpmccu commented 2 years ago

Fortunately, you have a good API, so I was able to work around the issue.

On Mon, Jun 20, 2022 at 9:03 AM Robert Hoehndorf @.***> wrote:

Hello,

AberOWL does SPARQL query rewriting but does not provide its own SPARQL endpoint (see the original paper, https://link.springer.com/article/10.1186/s12859-015-0456-9).

But you are right that this is not particularly useful; we will add this as enhancement to put in the next release.

— Reply to this email directly, view it on GitHub https://github.com/bio-ontology-research-group/aberowlweb/issues/120#issuecomment-1160421626, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAETCEKU3TLA5GA3KOKYJETVQBTYTANCNFSM5OUZHKFA . You are receiving this because you authored the thread.Message ID: @.***>

-- Jamie McCusker (she/her/hers)

Director, Data Operations Tetherless World Constellation Rensselaer Polytechnic Institute @. @.> http://tw.rpi.edu