Closed
Description
Describe the bug
Formatting failure on code that I think should succeed
To Reproduce
Try to format:
CREATE OR REPLACE VIEW someview AS
WITH some_cte AS (
SELECT
CASE
WHEN foo = bar THEN 1
ELSE 0
END AS biz
FROM
BAT
)
select * from some_cte
Expected behavior
Expecting formatting to succeed without an error.
Actual behavior
sqlfmt encountered an error: Closing bracket ')' found at 167 does not match last opened bracket 'CASE' found at 65.
Additional context
What is the output of sqlfmt --version
?
0.14.2
but I was able to reproduce it on the https://sqlfmt.com/ sandbox as well.
Activity