Hi!

This is the runQuery method:

    static Context context = new Context();
    static LocalSession session = new LocalSession(context);

    public DBResult runQuery(String query) throws QueryException {
        try {
            LocalQuery lq = session.query(query);
            DBResult db = new DBResult(lq);
            return db;
        } catch (Exception e) {
            PPLogger.getInstance().error("Error in runQuery: " + e.getMessage(), e);
            throw e;
        }
    }

and this is the relevant part of the DBResult class:
************************************************************************************************
    private LocalQuery results;

    public DBResult(LocalQuery results) {
        Assertion.assertNotNull(results, "Results are null");
        this.results = results;
    }

    public LocalQuery getXmlResults() {
        return results;
    }
************************************************************************************************
As I mention, I am not able to give an example that will reproduce the error every time, but it seems to occur randomly, and not very often :-(

Ketill

On Wed, Jun 10, 2015 at 11:49 AM, Christian Grün <christian.gruen@gmail.com> wrote:
Hi Ketill,

> The error occurs randomly, but is always "triggered" by "results.more()" and
> I am not able to reproduce it at will. Is there something wrong or missing
> in how I iterate the results?

If you want, you can pass me the missing Java functions, as I not know
too little about what e.g. getXmlResult does. Ideally, of course, we
would be happy to have a self-contained example that we can test.

Best,
Christian


> I am using BaseX8.2.1 on windows 7.
>
> Kind regards
> Ketill Fenne
>