From fdb8adc22baf5ec4520c3580af12747a0a3fc6ce Mon Sep 17 00:00:00 2001 From: Mattias Persson Date: Thu, 14 Mar 2013 21:19:23 +0100 Subject: [PATCH] Removed node scan when looking up nodes from index --- .../executionplan/builders/EntityProducerFactory.scala | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/community/cypher/src/main/scala/org/neo4j/cypher/internal/executionplan/builders/EntityProducerFactory.scala b/community/cypher/src/main/scala/org/neo4j/cypher/internal/executionplan/builders/EntityProducerFactory.scala index df2b6e47f2cbc..f89999a0b185a 100644 --- a/community/cypher/src/main/scala/org/neo4j/cypher/internal/executionplan/builders/EntityProducerFactory.scala +++ b/community/cypher/src/main/scala/org/neo4j/cypher/internal/executionplan/builders/EntityProducerFactory.scala @@ -85,14 +85,9 @@ class EntityProducerFactory(planContext: PlanContext) { val expression = valueExp getOrElse (throw new InternalException("Something went wrong trying to build your query.")) - val label = DynamicLabel.label(labelName) - (m: ExecutionContext, state: QueryState) => { val value = expression(m)(state) - state.query.exactIndexSearch(indexId, value) // This is the real call. The next is not the call you are looking for - state.query.nodeOps.all.filter { - case node:Node => node.hasLabel(label) && node.getProperty(propertyName, null) == value - } + state.query.exactIndexSearch(indexId, value) } }