Re: Incorrect result when lucene index is present


Hi inverseintegral,

You have been quite succesful as a test driver, that is detecting easily reproducible issues!
The current issue seems more like an issue of undefined behaviour, rather than an issue related to Lucene or UUID objects.
I get the same behaviour when using cql and elasticsearch:

graph ='conf/')
g = graph.traversal();
m = graph.openManagement();

l = m.makeVertexLabel("L").make();
p = m.makePropertyKey("p").dataType(Integer.class).make();
q = m.makePropertyKey("q").dataType(Integer.class).make();
m.buildIndex("someName", Vertex.class).addKey(p).addKey(q).indexOnly(l).buildMixedIndex("search");

g.addV("L").property("p", 1).next();

// ==> 0
g.V().hasLabel("L").has("q", not(eq(2))).count()
// ==> 1
The CompositeIndex, though, has the same behaviour as the case without index (counts 0 and 0). The reference docs do not expand on the use of multiple property keys in an index after adding them.

Apparently, when querying a mixed index with a neq() predicate, it is not checked whether the associated property exists or is non-null in the index for that graph element.
You can make an issue, again, if you want. Any interest in providing a PR for any of the issues you found? I am sure people on will want to help you if you would get stuck in the PR process. See also .

I checked for related issue, but only could be related.

Best wishes,   Marc

Join { to automatically receive all group messages.