Does anyone know of a routine for formatting SQL statements in a
structured way? Standalone or for emacs would be fine.  I'm thinking of
something that could take a long SQL text statement and format it, e.g.:

select foo from bar where baz and bop and not boo;

becomes

SELECT     foo
FROM       bar
WHERE      baz
   AND     bop
   AND NOT boo
;

Thanks,
Andy

----------------------------------------------------------------------
Andrew J Perrin - http://www.unc.edu/~aperrin
Assistant Professor of Sociology, U of North Carolina, Chapel Hill
[EMAIL PROTECTED] * andrew_perrin (at) unc.edu



---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/users-lounge/docs/faq.html

Reply via email to