neo4j / cypher-language-support

Neo4j's Cypher Language support

Home Page:https://neo4j.github.io/cypher-language-support/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Add jump to definition capabilities

ncordon opened this issue · comments

Add the ability to jump to definition for a variable in a query:

MATCH (this:`Person`)
WHERE (this.name STARTS WITH $param0 AND EXISTS {
    MATCH (this)-[:ACTED_IN]->(this0:`Movie`)
    WHERE (this0.title CONTAINS $param1 AND EXISTS {
        MATCH (this1:`Person`)-[:ACTED_IN]->(this0)
        WHERE (this1.name CONTAINS $param2 AND EXISTS {
            MATCH (this1)-[:ACTED_IN]->(this2:`Movie`)
            WHERE (NOT (this2.title = $param3) AND EXISTS {
                MATCH (this3:`Person`)-[:ACTED_IN]->(this2)
                WHERE (this3.name CONTAINS $param4 AND NOT (EXISTS {
                    MATCH (this3)-[:ACTED_IN]->(this4:`Movie`)
                    WHERE this4.title = $param5
                }))
            })
        })
    })
})


RETURN this { .name } AS this

When I click on the this, it would take me to the this in the first line of the query.

This would require some scope information for the variables (semantic table perhaps). It would be great for big queries to be able to jump to where the variable was first defined.

Moved to Trello!