Hi,
Let me start with praising Textpad! I use this so extensively and for everything (most of the work). I wish it had code/sql beautifier.
Is there any add-on or external utility that I can use with Textpad to beautify the selected sql code/query?
I found some online options like this which I use to launch it from Textpad using External Tools. In this case I copy my sql and paste it here and copy-and-paste it back in Textpad.
http://www.dpriver.com/pp/sqlformat.htm
I also found a command line tool at http://poorsql.com/ but I don't know how to call it from Textpad to format the sql and bring the results back in Textpad. Even if somebody can help me get the results into clipboard, that would be of great help too.
Thanks.
Beautify SQL
Moderators: AmigoJack, bbadmin, helios, Bob Hansen, MudGuard
If you can manage to find a command-line utility that outputs the SQL code to standard output, you can pipe the output to the clip command that comes with Windows Vista and later.
However, I tried the Poor SQL tool you mentioned and could not get it to work with TextPad at all. Whenever I tried to invoke it as an external tool, SqlFormatter.exe would crash with a "System.IO.IOException: The handle is invalid" exception.
However, I tried the Poor SQL tool you mentioned and could not get it to work with TextPad at all. Whenever I tried to invoke it as an external tool, SqlFormatter.exe would crash with a "System.IO.IOException: The handle is invalid" exception.