An important aspect of writing code is formatting. No one likes badly formatted code. It’s hard to understand/maintain for people inheriting it and even for the author, when he/she checks it after week or so

I do understand that developers work under strict delivery guidelines and no one would want to delay the delivery on expense of formatting the code, making it nice and beautiful. However, with free T-SQL formatters it hardly takes time and one gets a clean formatted code without delaying the release. Here is list of T-SQL code formatters.

  1. Poor Man’s T-SQL formatter

It’s Open source T-SQL formatter. It is available both online – www.poorsql.com and as SSMS plugin http://architectshack.com/PoorMansTSqlFormatter.ashx#Download_5

  1. TSQL Tidy

It’s available online at www.tsqltidy.com and it is also available as SSMS plugin at http://www.tsqltidy.com/tsqltidySSMSAddin.aspx

  1. Instant SQL Formatter

The free online tool is available here http://www.dpriver.com/pp/sqlformat.htm

  1. SQL Format

The free online tool is available here http://sqlformat.org

  1. ApexSQL Refactor

The free tool is available here – http://www.apexsql.com/sql_tools_refactor.aspx

  1. SQL-Format

The online free tool is available here http://www.sql-format.com/

  1. Dbforge SQL Complete

It is a paid tool and is available here http://www.devart.com/dbforge/sql/sqlcomplete/.

  1. The simple talk code prettifier

The free online tool is available here http://extras.sqlservercentral.com/prettifier/prettifier.aspx

  1. RedGate SQL Prompt

Paid tool available here http://www.red-gate.com/products/sql-development/sql-prompt/

10. SSMS tools pack

It is available here http://www.ssmstoolspack.com/

Make use of the free tools and write a clean formatted code. Do add to the list if you know of any other formatting tool.

 

Regards

Ahmad Osama

Like us on FaceBook Join the fastest growing SQL Server group on FaceBook

Follow me on TwitterFollow me on FaceBook