I am beginner in SPARQL and in my current task I have to delete some triples where the subject matches a specific string. I am running this delete query on a graph in Blazegraph.
This is my query:
prefix skos: <http://www.w3.org/2004/02/skos/core#>
prefix rdfs: <http://www.w3.org/2000/01/rdf-schema#>
delete DATA {GRAPH <http://example.org/mapping>
{ ?s ?p ?o}
}
WHERE { ?s ?p ?o .FILTER regex(str(?s), "omim") .}
However, I get this error after running the above query:
Was expecting one of:
"base" ...
"prefix" ...
"select" ...
"construct" ...
"describe" ...
"ask" ...
How should I modify the current query to delete the triples like this below:
s p o
<https://www.omim.org/entry/202110> rdfs:label ADRENAL HYPERPLASIA, CONGENITAL, DUE TO 17-ALPHA-HYDROXYLASE DEFICIENCY
<https://www.omim.org/entry/202110> skos:exactMatch <https://identifiers.org/meddra:10000014>
Any help is highly appreciated.