Skip to content
| Marketplace
Sign in
Visual Studio Code>Programming Languages>Highlighting Inline SQL and PRQLNew to Visual Studio Code? Get it now.
Highlighting Inline SQL and PRQL

Highlighting Inline SQL and PRQL

yicone

|
627 installs
| (0) | Free
Syntax Highlighting for SQL and PRQL in js/jsx/ts/tsx template literals, go template literals, python multi-qutoted/f-strings
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

Highlighting Inline SQL & PRQL for VS Code

Syntax Highlighting for SQL and PRQL in JS template literals in .js/.jsx/.ts/.tsx, Go template literals, Python multi-qutoted/f-strings.

Acknowledgements

I would like to thank the following projects, which were instrumental in the development of this project:

  • ptweir/python-string-sql

Thank you to the maintainers and contributors of these projects!

Requirements

  • For PRQL highlighting, you need to install the PRQL extension first

Installation

Install Highlight Inline SQL from the Extensions Marketplace (ctrl + shift + x or cmd + shift + x on mac).

Also available on marketplace.visualstudio.com

Example

Example Example

Usage

Insert --sql, --beginsql, or --begin-sql at the beginning of the part of the string you would like highlighted and a semicolon, --endsql, or --end-sql at the end of the highlighted section.

For PRQL, Insert --prql, --beginprql, or --begin-prql at the beginning of the part of the string you would like highlighted and a semicolon, --endprql, or --end-prql at the end of the highlighted section.

Snippets

begin typing sql and the autocomplete snippet will appear:

Snippet

There was prql for PRQL also.

Keybindings

ctrl+k s (or cmd+k s on macOS) - Insert the following snippet:

"""
--sql
SELECT
;
"""

For PRQL, the keybinding is: ctrl+k p (or cmd+k p on macOS)

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