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

Add option to toggle trailing commas in SELECT columns list #24

Open
nene opened this issue Feb 6, 2024 · 0 comments
Open

Add option to toggle trailing commas in SELECT columns list #24

nene opened this issue Feb 6, 2024 · 0 comments

Comments

@nene
Copy link
Owner

nene commented Feb 6, 2024

Currently the plugin strips trailing commas to enforce a consistent syntax across all SQL dialects. Trailing commas are not part of the SQL standard and are only supported by a few dialects.

However, in dialects that support them (like BigQuery), it's a really nice feature. In other dialects many users resort to using comma-first style to solve the problem for which trailing commas is a much nicer solution.

Something like sqlSelectTrailingComma: "always" | "never" | "preserve". Possibly the "preserve" isn't even needed as it opens a door for inconsistent style.

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

1 participant