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

ALTER TYPE for postgres should be valid #237

Closed
patextreme opened this issue Jan 18, 2023 · 1 comment
Closed

ALTER TYPE for postgres should be valid #237

patextreme opened this issue Jan 18, 2023 · 1 comment

Comments

@patextreme
Copy link

patextreme commented Jan 18, 2023

An error was raised when encountered ALTER TYPE ..... statement running sql-lint through megalinter

Steps to reproduce

  • create some .sql file with ALTER TYPE foo RENAME TO bar;
  • run megaliter with this option SQL_SQL_LINT_ARGUMENTS: -d postgres

Output

[sql-lint: postgres-invalid-alter-option] Option 'type' is not a valid option, must be one of '["column","online","offline","ignore","database","event","function","procedure","server","table","tablespace","view"]'.

In my case, the --ignore-errors=postgres-invalid-alter-option flag was added as a workaround.

Expected Bahavior

No error from linter. ALTER TYPE ... should be valid. https://www.postgresql.org/docs/current/sql-altertype.html

@joereynolds
Copy link
Owner

Hey @patextreme , this has been fixed. Thanks :)
#272

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

No branches or pull requests

2 participants