albertoventurini / graphdb-intellij-plugin

Graph database plugin for the IntelliJ Platform
https://plugins.jetbrains.com/plugin/20417-graph-database
Apache License 2.0
50 stars 14 forks source link

Formatter produces error when using full-text index #93

Open Dimibe opened 4 months ago

Dimibe commented 4 months ago

Hello,

I came across the problem that I use a full-text index search (db.index.fulltext.queryNodes) in my query. The function returns a node and score variable, e.g.

CALL db.index.fulltext.queryNodes('userNames', ('*' + $text + '*')) YIELD node AS user, score

The problem is that the formatter of this plugin identifies the word node as a keyword and reformats the code to:

CALL db.index.fulltext.queryNodes('userNames', ('*' + $text + '*')) YIELD NODE AS user, score

With that, the query throws an exception because the variable must be named node and not NODE. Would it be possible to not reformat the word node to uppercase?

See also: Full-text indexes

Thanks in advance.