neueda / jetbrains-plugin-graph-database-support

Graph Databases support for JetBrains family IDEs.
Apache License 2.0
222 stars 56 forks source link

Editor incorrectly interprets variable length path bound variables as Relationship instead of a list #54

Closed rdpickard closed 6 years ago

rdpickard commented 7 years ago

This is a UI bug, it does not impact the execution of a query from the plugin.

In following neo4j query

MATCH (a)-[c*1..1]->(b)
WITH size(c) as derp
return derp

the c in size(c) will get flagged as an error (red squiggle underline and red strike in the right gutter) with the text expected LIST OF ANY, got RELATIONSHIP.

This is an inaccurate warning because a MATCH with a specified length path returns the bound variable as a list, not a relationship. This behavior is described in the neo4j documentation

Again, this does not impact executing the query, it just is a bit misleading.

FylmTM commented 7 years ago

Thanks @rdpickard ,

Great catch. It should be easily fixable. I will look into this in next few days.