Open haoliangyu opened 4 months ago
While ElasticSearch allows . (or other special characters) in the index name, the SQL generated from this provider will fail with a parsing error. Double-quoting the index name will fix the issue.
.
This does not work
SELECT * FROM index.name
This works
SELECT * FROM "index.name"
It is mentioned at the ElasticSearch SQL documentation:
If the table name contains special SQL characters (such as .,-,*,etc…) use double quotes to escape them
This bug can be fixed at https://github.com/koopjs/koop-provider-elastic-sql/blob/main/src/model.js#L130.
Thanks @haoliangyu.
While ElasticSearch allows
.
(or other special characters) in the index name, the SQL generated from this provider will fail with a parsing error. Double-quoting the index name will fix the issue.This does not work
This works
It is mentioned at the ElasticSearch SQL documentation:
This bug can be fixed at https://github.com/koopjs/koop-provider-elastic-sql/blob/main/src/model.js#L130.