Thanks Andy! I change the command to this and it works:

DELETE WHERE
{
 ?s ?p ?o
}

Follow up question, right now I subclass Jena's DatasetGraphBase class, and 
override the delete method, i.e.:

    @Override
    public void delete(Quad quad) {
        // call our lib to delete that specific quad from back-end store
    }

Follow up question below...
I see this can become performance issue when there are many rows involved like 
in this case
I see I can override deleteAny method, and create iterator and handle the batch 
myself, like the template code in DatasetGraphBase.java
But it looks like deleteAny method is only called from CLEAR command.
Is it possible to implement batch deletion for DELETE WHERE command? Or is 
there a better way doing this from Jena?


Thanks,
Z

________________________________________
From: Andy Seaborne <[email protected]>
Sent: Tuesday, September 29, 2015 11:40 AM
To: [email protected]
Subject: Re: delete all triples

On 29/09/15 16:06, Zen 98052 wrote:
> Is it possible to delete all triples? I tried this command below, and got 
> error saying variables are not permitted.
>
>
> DELETE DATA
>
> {
>   ?s ?p ?o
> }
>
>
> Thanks,
> Z
>
>

Hi - the relevant specs are:

http://www.w3.org/TR/sparql11-update/

http://www.w3.org/TR/sparql11-http-rdf-update/

        Andy

Reply via email to