Andy,

Thanks and that worked by the way.  I am using maven and have these setting, so 
I get the latest:
jena-arq:  <version>2.9.1-incubating-SNAPSHOT</version>

jena-tdb:  <version>0.9.1-incubating-SNAPSHOT</version>



Now, I am having a similar issues as before, but with using the model to add a 
statement (vs before was TDBLoader) and the issue is between restarts of the 
JVM.


If, I use this:

    model.add(statement);
    TDB.sync(dataset);



on a restart, I get a count of 1 with my Count query, but no visible results 
with my All query:

1) All query:         "SELECT * {?s ?p ?o}"
2 ) Count query:   "SELECT (count(*) AS ?count) { ?s ?p ?o }" 



But, if I change the TDB.sync(dataset) to model.close(), it does work, and I 
see the results as well as still the count of 1.



So, do I need to close the model after an add, or call some other method to 
sync, or is it a bug....???


 
Tkx,
Jim



________________________________
 From: Andy Seaborne <a...@apache.org>
To: jena-users@incubator.apache.org 
Sent: Monday, April 16, 2012 12:07 PM
Subject: Re: Loading OWL and TDB
 
On 16/04/12 16:33, Jim Reilly wrote:
> Andy,
> 
> I tried the TDB.sync without the model.close, but that did not work
> (meaning no data shown after a JVM re-start).

Lack of clarity on my part.

There is a bug in the 0.9.0 release whereby sync of a dataset was not getting 
passed down to the storage correctly (this is JENA-234). dataset.close should 
do a sync if the dataset has not been used for transactions at all, that is, 
it's running in 0.8 style.  The dataset implementation in TDB 0.9.0 behaves 
non-transactionally until used in some transaction - this is to maximise 
compatibility with existing code.

Unfortunately, JENA-234 means that .close was not causing a sync and sync was 
not getting propagated properly. Fixed now in development builds and svn.

The development build 0.9.1-incubator-SNAPSHOT (via [1] as described in [2])

    Andy

[1] 
https://repository.apache.org/content/repositories/snapshots/org/apache/jena/

[2] http://incubator.apache.org/jena/download/maven.html

Reply via email to