Basic

This is an example of a SQL statement.

vkBeautify SQL parser covers only SELECT statement as most javascript developers have deal with SELECT-based queries. As SELECT syntax itself is very large and flexible, some complex nested statements can be formatted not as perfect as you'd make it manually. But anyway, it helps you to save time on reading unformatted SQL statement.

Note: "Preserve Comments" is not implemented for SQL part of the application.

Click on "Pretty Print" button to beatify the text.

Click on "Minify" button to minify the text * (not sure if anybody needs it, but I keep it for consistency :)

Custom Indent Pattern:
By default indent pattern is 4 white spaces. However, user can customize as pattern size as pattern characters. There are 2 ways to customize indent pattern:

  • set number of white spaces as numeric value:
    2, 4, etc.
  • set desired pattern as a string, for example:
    '. . . .'
    '____'
    '- - - -'
    '       '  -  string of white spaces is also valid.
Clear input to return to the default indent pattern.

* minify() function works only with whitespace pattern.