On 22/10/11 14:47, Bill Roberts wrote:
On 22 Oct 2011, at 14:37, Rob Stewart wrote:
Hi,
I have a joseki sparql endpoint set up. I am testing SPARQL Update.
The following works:
PREFIX dc:<http://purl.org/dc/elements/1.1/>
PREFIX ns:<http://example.org/ns#>
INSERT DATA
{<http://example/book1> ns:price 42 }
----
However, this does not work:
PREFIX dc:<http://purl.org/dc/elements/1.1/>
PREFIX ns:<http://example.org/ns#>
INSERT DATA
{ GRAPH<http://example/bookStore> {<http://example/book1> ns:price 42 } }
This works fine for me on Joseki 3.4.4. (I'm using the 'UnionDefaultGraph'
option - not sure if that makes any difference). I can't see anything wrong
with it so not sure why you are getting an error.
For me, the first example (where no graph is specified) executes without error,
but the triple is not retrieved when I do a SELECT for it - I presume this is
because my default graph is the union of named graphs, so stuff in un-named
graphs is somehow 'lost'.
Bill - not so much "lost" as "hidden". Updates do go to the real default
graph but that is masked by the union default graph in the query.
Andy