I want to decorate the SQL queries that I am writing.
What free tools exist to format a SQL query?
PoorMansTSqlFormatter is a free, open-source online developer with a standalone SSMS add-in, command line enhancement tool and Notepad ++ plugin.
The goal of the project is to format any T-SQL (2000 or newer) script, regardless of its length or complexity.
Hope this helps!
T-SQL Tidy is a very good SQL online formatter / decoder.
It has many formatting options. Although it targets T-SQL, it should work with most SQL dialects.
There is a free online Instant SQL Formatter . The site also sells some other versions (for example, an add-in for Visual Studio), but the online version is free.
red Jul 22 '10 at 15:13 @Christopherous 5000
I searched the same thing in notepad ++ and found a link that gives an idea of โโhow to create my own formatting using macros: http://peoplesoft.wikidot.com/formatting-sql-in-notepad . This seems to work, but I'm going to use one of the SSMS add-ons above. (Less work) Thank you!
I have always been a fan of navicat - http://www.navicat.com
Their lite version is free, but it still comes with an sql constructor - http://www.navicat.com/en/products/navicat_premium/premium_feature.html
As an added bonus, sometimes you find that chinglish is hiding in strange places.
Sequel Pro If you use OS X, otherwise just work out what you need and then develop your request using your knowledge and use the command line tool (my personal favorite :)).