Hello,

I'm trying to make a SPARQL update query over a model, the problem is that
the query has to delete a triple belonging to a specific graph:

PREFIX dc:    <http://purl.org/dc/elements/1.1/>
DELETE {
        GRAPH <http://3cixty.com/cotedazur/test> {
                <
http://data.linkedevents.org/event/51f5ecc8-55b4-3a1b-98de-55e4448ab7bf>
dc:identifier ?o .
            }
        } WHERE {
            GRAPH <http://3cixty.com/cotedazur/test> {
                <
http://data.linkedevents.org/event/51f5ecc8-55b4-3a1b-98de-55e4448ab7bf>
dc:identifier ?o .
            }
}

which apparently has no effect when we proceed that way:

Model model = RDFDataMgr.loadModel("file.ttl");
UpdateAction.parseExecute(sparql_query, model);

I suppose it is normal as I never created the graph in the model.
Nevertheless when I do:

Model model = ModelFactory.createModelForGraph(new
SimpleGraphMaker().createGraph("http://3cixty.com/cotedazur/test";));
model.read("file.ttl");
UpdateAction.parseExecute(sparql_query, model);

It has no effect as well. Can someone guide me on how to do such thing
properly?

Thanks in advance.

Regards.
--
Julien Plu

PhD Student at Eurecom.
Personal webpage: http://jplu.developpez.com
FOAF file : http://jplu.developpez.com/julien
Email address : [email protected] && *[email protected]
<[email protected]>*
Phone : +33493008103
Twitter : @julienplu

Reply via email to