I'm experiencing what appears to be a bug using "WITH <graph> INSERT/WHERE"
in the latest Fuseki release (2.3.1).  If I attempt to insert a triple with
a predicate of 'rdf:type' (or 'a') it gets inserted into the default graph;
other triples get correctly inserted into the specified graph.  The
following is an example insert that will demonstrate the problem.  After
the insert the triple with the rdf:type predicate will be in the default
graph and the triple with the common:hasCreateTime triple will be in the
testGraph.  I expect both triples to be in the "testGraph" graph

PREFIX common: <http://www.example.com/common>
PREFIX entryNS: <http://www.example.com/entries>
PREFIX testGraph: <http://www.example.com/testGraph>

WITH testGraph:
INSERT {
  entryNS:c02db2e0-a4e3-11e5-8b21-63a5a521ceff a common:SomeClass ;
    common:hasCreateTime ?now .
}
WHERE {
  BIND(now() as ?now)
}

If, however, I don't use WITH and specify the graph inside the INSERT
clause using GRAPH <graph> {} it works as expected.  For example:

PREFIX common: <http://www.example.com/common>
PREFIX entryNS: <http://www.example.com/entries>
PREFIX testGraph: <http://www.example.com/graph>

INSERT {
  GRAPH testGraph: {
    entryNS:c02db2e0-a4e3-11e5-8b21-63a5a521ceff a common:SomeClass ;
      common:hasCreateTime ?now .
  }
}
WHERE {
  BIND(now() as ?now)
}

Am I not understanding the semantics of how WITH <graph> works.... or is
this a problem with the latest release.  This was not the case with 2.3.0

Thanks,

Howard Burrows

Reply via email to