[Feature] Better parsing of indexing SQL statements
Description
Currently we parse indexing SQL statements with our own homegrown parser. It needs to be updated in order to support the new kinds of indexes. Discussion here shows some of deficiencies. In particular the fn is_same_kind_columns in index.rs has to jump through some hoops in order to compare if the two expressions are "kind of same". For instance BlockRangeLower and Unknown("lower(block_range) int4_minmax_multi_ops)"). Also the test generate_ddl() has a commented out line in the mock_thing_index_list for the same reason.
Related to this is generator of SQL statements that is not perfectly sanitising it's output, somewhat addressed in this.
One approach would be to extend the current parser to handle those cases. Other would be to use sqlparser or similar.
Are you aware of any blockers that must be resolved before implementing this feature? If so, which? Link to any relevant GitHub issues.
No response
Some information to help us out
- [ ] Tick this box if you plan on implementing this feature yourself.
- [X] I have searched the issue tracker to make sure this issue is not a duplicate.
Looks like this issue has been open for 6 months with no activity. Is it still relevant? If not, please remember to close it.
Hi!
We're refreshing the graph-node issue backlog to help focus on current priorities and make it easier to track and address relevant issues. As part of this cleanup, we're closing issues created in 2025 or earlier.
If this issue is still relevant, please open a new issue (linking back to this one) or leave a comment here with any updated context and tag @dimitrovmaksim, so we can reassess and prioritize it.
Thank you for your contributions to graph-node! 🙏