Home / Companies / Cockroach Labs / Blog / Post Details
Content Deep Dive

sqlfmt: A SQL formatter for writing prettier SQL

Blog post from Cockroach Labs

Post Details
Company
Date Published
Author
Matt Jibson
Word Count
1,721
Company Posts That Month
11
Language
English
Hacker News Points
207
Post removed?
No
Summary

sqlfmt is an online SQL formatter that aims to beautifully format SQL statements by understanding all CockroachDB syntax, attempting to use available horizontal space in the best way possible, and maintaining visual alignment regardless of editor configuration. It was designed with a focus on using available space efficiently and adapting to the complexity of the query. The tool is based on a paper describing an algorithm for efficient document layout with multiple possible layouts, initially implemented in Haskell and later converted into Go. sqlfmt is not highly customizable and aims to remove options over time as it evolves.

Trends Found in this Post
Trend Post Mentions Total Month Mentions Posts Companies MoM
Serverless 1 828 108 53 +28%
Use This Data

Use this post, company, and trend context to find content marketing opportunities, perform competitive analysis, or address product feature gaps via the Plushcap MCP server or the Plushcap API.