Hi,
I've followed the examples in chapter 16 of the virtuoso online
documentation :
http://docs.openlinksw.com/virtuoso/rdfnativestorageproviders.html
As I understand it, if I use the virtuoso jena provider, I can insert or
remove triples
from a named graph very easily:
Node foo1 = Node.createURI("http://example.org/#foo1");
Node bar1 = Node.createURI("http://example.org/#bar1");
Node bar2 = Node.createURI("http://example.org/#bar2");
Node baz1 = Node.createURI("http://example.org/#baz1");
VirtGraph graph = new VirtGraph ("Example5", url, "dba", "dba");
graph.clear ();
graph.add(new Triple(foo1, bar1, baz1));
graph.add(new Triple(foo1, bar2, baz1));
All the operations are transactional and I can rollback at any time:
graph.getTransactionHandler().begin();
graph.add(new Triple(foo1, bar1, baz1));
graph.add(new Triple(foo1, bar2, baz1));
graph.getTransactionHandler().abort();
Now, I would like to make multiple insertions under different named graphs
within the same transactional scope.
That means that if an error occurs during one of the insert queries
execution, all the operations should be rolled back.
Is it possible with multiple named graphs and the virtuoso jena provider?
If it is the case could you please provide some examples?
Thank you.
Regards,
Jonathan Dray