Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>JMAN SQL FormatterNew to Visual Studio Code? Get it now.
JMAN SQL Formatter

JMAN SQL Formatter

Cavinkumaran-m

|
9 installs
| (1) | Free
A lightweight SQL formatter extension for Visual Studio Code built for teams with custom SQL formatting conventions.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

JMAN SQL Formatter

A lightweight SQL formatter extension for Visual Studio Code built for teams with custom SQL formatting conventions.

JMAN SQL Formatter helps standardize SQL files across projects by applying consistent formatting rules while preserving readability and developer workflow.


Features

✨ SQL Document Formatting

Format SQL files directly inside VS Code using:

  • Shift + Alt + F
  • Right Click → Format Document
  • Command Palette → JMAN SQL Formatter: Format Document

📁 Format Entire Workspace

Format all SQL files in your workspace at once:

  • Command Palette → JMAN SQL Formatter: Format Directory
  • A confirmation dialog will appear to prevent accidental formatting
  • Progress indicator shows file-by-file formatting status
  • Failed files are reported without interrupting the batch process

🧠 Smart SQL Formatting

Supports:

  • SQL keyword formatting
  • Consistent indentation
  • Line breaks
  • Readability improvements
  • Company-specific formatting rules

Example:

Before

select id,name from users where active=1;

After

SELECT

    id
    , name

FROM users

WHERE
    active = 1
;

🚨 SQL Error Highlighting

When formatting fails due to invalid SQL syntax:

  • The exact error line is highlighted
  • Errors appear in the Problems panel

🛠 dbt & Jinja Friendly

Built with templated SQL workflows in mind.

Example:

Before

SELECT {{ dbt_utils.generate_surrogate_key(['id']) }}, name, age FROM {{ ref('users') }}

After

SELECT

    {{ dbt_utils.generate_surrogate_key(['id']) }}
    , name
    , age

FROM {{ ref('users') }}

Requirements

No additional setup required.

Supported environments:

  • Visual Studio Code ^1.100.0
  • SQL files
  • dbt SQL files (partial support)

Extension Settings

This extension contributes the following settings:

jmanSqlFormatter.sqlDialect

You can set the SQL dialect used for formatting through File -> Preferences -> Settings -> Search 'jman' and select desired dialect from the dropdown.

Currently supported dialects:

  • sql (default)
  • postgresql
  • mysql
  • sqlite
  • snowflake
  • tsql

Default:

"sql"

Usage

Format Current File

Open a SQL file and run:

Shift + Alt + F

or:

Command Palette → Format Document

Disable Formatting for Specific Blocks

Use special comments to prevent the formatter from formatting specific SQL blocks:

/* sql-formatter-disable */
SELECT * FROM tbl1;
/* sql-formatter-enable */
SELECT * FROM tbl2;

This is useful for:

  • Preserving manually formatted SQL blocks
  • Skipping non-standard or custom SQL syntax
  • Maintaining specific formatting conventions in certain sections

Known Issues

  • Complex templated SQL may not format perfectly
  • Some dialect-specific syntax may not yet be supported
  • Extremely malformed SQL can produce partial formatting

Release Notes

1.0.0

Initial release featuring:

  • SQL document formatting
  • VS Code formatter integration
  • SQL syntax diagnostics
  • Error highlighting

Contributing

Contributions, suggestions, and bug reports are welcome.


License

MIT License


Enjoy formatting SQL 🚀

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft