vscode-sqltools
vscode-sqltools copied to clipboard
Newlines before comments are sometimes removed
Describe the bug When formatting a Postgres SQL statement with a comment on its own line, the comment is placed at the end of the preceding line.
To Reproduce Paste this SQL statement into the online formatter playground at https://vscode-sqltools.mteixeira.dev/en/playground/formatter?umd_source=repository&utm_medium=readme&utm_campaign=formatter
SELECT * FROM my_table
-- test comment
WHERE x = 1;
Observe the result:
SELECT * FROM my_table -- test comment
WHERE x = 1;
Expected behavior The comment is kept on it's own line
Screenshots