-
Notifications
You must be signed in to change notification settings - Fork 405
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
Error formatting MariaDB CASE STATEMENT #780
Comments
Thanks for reporting. Unfortunately the support of procedural SQL in SQL Formatter is pretty weak. The specific problem happens because it really only understand the SQL CASE expression, but has next to no support for CASE statement. Fixing this is more akin to feature development and I've mostly stopped doing new feature development on SQL Formatter. I might suggest you instead give a try to prettier-plugin-sql-cst which has better MariaDB/MySQL support, including support for the above CASE statement. |
I can't identify whether the prettier-plugin-sql-cst you provide can be used for in VSCode? |
You can use it through the VSCode Prettier extension as it's just a plugin for Prettier. |
Fine. CREATE PROCEDURE and UNSIGNED is also not supported. 😭 |
Describe your problem
This code is copied from the MariaDB documentation so there should be no syntax errors:
An Unexpected Error Occurred
Parse error at token: SELECT at line 2 column 17 Unexpected RESERVED_SELECT token:
Which SQL dialect does this apply to?
MariaDB
Which SQL dialect is configured in your VSCode extension settings?
MariaDB
Version of the VSCode extension
4.1.1
I have tried to reproduce this issue on the demo page, and it
The text was updated successfully, but these errors were encountered: