In my current project I've been inherited with lots of long (1200+ lines) SQL Server stored procedures with some horrible indentation and formatting which makes them almost unreadable. Is there some tool that I can use to automatically format these and make them more readable? I don't want to go through it manually and indent it.
views:
1371answers:
6
+1
A:
Check out Sql assist:
It has some format feature.
http://www.roundpolygons.com/Default.aspx?PageContentID=5&tabid=92
I would suggest downloading the evaluation version to see whether it fits your need.
J.W.
2009-03-26 16:02:18
+4
A:
Here's a couple -- no idea how well they work, unfortunately...
http://www.wangz.net/gsqlparser/sqlpp/sqlformat.htm (free)
http://www.sqlinform.com/ (free for personal use)
mwigdahl
2009-03-26 16:03:10
SQLinform works very well, actually. Lots of options, you can lay out code the way you like best.
Tomalak
2009-03-26 16:09:19
+3
A:
Red Gate "SQL Refactor" Very good. We bought it
Or
SSMS tools pack Free, but we don't use the layout features
gbn
2009-03-26 16:05:57