neo4j-labs / neodash

NeoDash - a Dashboard Builder for Neo4j
https://neo4j.com/labs/neodash/
Apache License 2.0
397 stars 129 forks source link

[Parameter Select] Do not automatically sort results when set to Cypher query #856

Closed mariusconjeaud closed 2 months ago

mariusconjeaud commented 3 months ago

The Parameter Select dropdown is automatically sorted in alphabetical order for "Node Property", "Relationship Property" and "Cypher query" modes.

This then overrides any ORDER BY clause set in the Cypher query itself. For example : UNWIND ["Yes", "No"] As options RETURN options ORDER BY options DESC should show :

But it shows the reverse.

Since users are in control of ordering when using the "Cypher query" mode, we should disable the auto-sort in this mode (and keep for Node and Rel Property because it makes sense).