Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deparse of index with period (.) in name leads to syntax error #77

Closed
lwithers opened this issue Feb 23, 2023 · 1 comment · Fixed by pganalyze/libpg_query#182
Closed

Comments

@lwithers
Copy link

Hi,

If I parse and then de-parse the following statement:

CREATE INDEX "foo.index" ON foo USING btree (bar)

then I end up with a result where the index name is unquoted, which is a syntax error:

CREATE INDEX foo.index ON foo USING btree (bar)

PostgresQL (tested on 10.23 and 15.1) reports:

postgres=# CREATE INDEX foo.index ON foo USING btree (bar);
ERROR: syntax error at or near "." (SQLSTATE 42601)
@lfittl
Copy link
Member

lfittl commented Feb 26, 2023

@lwithers Thanks for the report - that's an oversight in the deparser code, see pganalyze/libpg_query#182

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants