Fix for #137 - transaction.setBatchFlushOnQuery(false) not working for
some queries