Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
04-22-2020 04:54 AM
I am getting this error which I really feel it's a bug
org.neo4j.cypher.internal.physicalplanning.ast.NullCheckReference
So lets take this from the beginning.
When I run this query everythinks works fine.
match (manufacturer)-[:HAS_BRAND]-(brand:Brand)-[:HAS_VARIANT]->(variants:Variant)
with manufacturer, brand, collect(variants) as variantList
unwind variantList as variant
Unwind range(1,variantList.nCars) as carID
return manufacturer,variant,carID
In my results and when checking the Table I see this:
manufacturer variant carID
{name:"VW",.. } {name:"Golf", nCars:12} 1
{name:"VW",.. } {name:"Golf", nCars:12} 2
{name:"VW",.. } {name:"Golf", nCars:12} 3
.....
{name:"VW",.. } {name:"Golf", nCars:12} 12
{name:"VW",.. } {name:"Tiguan", nCars:3} 1
{name:"VW",.. } {name:"Tiguan", nCars:3} 2
.............
So you can see the table looks alright.
But when I change my query to this.
match (manufacturer)-[:HAS_BRAND]-(brand:Brand)-[:HAS_VARIANT]->(variants:Variant)
with manufacturer, brand, collect(variants) as variantList
unwind variantList as variant
Unwind range(1,variantList.nCars) as carID
create (:Car {name: manufacturer.name + ' - ' + variant.name + ' - Car ' + carID})
.. I get the above error org.neo4j.cypher.internal.physicalplanning.ast.NullCheckReference
.
I notice that if I change the last line to create (:Car {name: manufacturer.name + ' - Car ' + carID})
everything works i.e. I removed the variant.name.
Anyway this doesn't make sense and also I want to have that name.
Please help
04-22-2020 05:06 AM
I found a way to do this but still doesn't explain the previous error.
Anyway my fix is
match (manufacturer)-[:HAS_BRAND]-(brand:Brand)-[:HAS_VARIANT]->(variants:Variant)
Unwind range(1,variants.nCars) as carID
create (:Car {name: manufacturer.name + ' - ' + variants.name + ' - Car ' + carID})
04-22-2020 02:05 PM
what version of Neo4j?
When you run he query which results in failure is there a stacktrace logged in the logs\debug.log?
04-23-2020 12:54 AM
I used version 4.0.3.
Sorry I have moved on and can't check the log file now.
Is it saved from yesterday?
Thanks
04-23-2020 04:43 AM
the log should be saved unless it got auto rotated off however I believe the default is to keep 7 days worth
But also we encountered a similar org.neo4j.cypher.internal.physicalplanning.ast.NullCheckReference
and have addressed this in the next release of 4.0.x and thus this will be addressed in 4.0.4 (not yet released). However whether of not it is the exact same root cause as yours is not yet known given the absence of a complete logged stack trace. It may be one in the same? may be ?? or
All the sessions of the conference are now available online