Re: How would I get rid of trailing blank line?
| От | Greg Sabino Mullane |
|---|---|
| Тема | Re: How would I get rid of trailing blank line? |
| Дата | |
| Msg-id | f2bd06ed8591a98155db624596667332@biglumber.com обсуждение |
| Ответ на | How would I get rid of trailing blank line? ("Tena Sakai" <tsakai@gallo.ucsf.edu>) |
| Список | pgsql-sql |
-----BEGIN PGP SIGNED MESSAGE----- Hash: RIPEMD160 > report at the bottom. There is a blank line > at the bottom, however. Is there any way to > have psql not give me that blank line? Now that my presenation on psql is over :), I'll share my solution: psql -AX -qt -c "SELECT ..." | perl -pe 's/^\n// if $.<2' This strips a newline from the first line only of the output, and only if the line consists of nothing else. Highly recommended for cron. - -- Greg Sabino Mullane greg@turnstep.com End Point Corporation PGP Key: 0x14964AC8 200904052221 http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8 -----BEGIN PGP SIGNATURE----- iEYEAREDAAYFAknZZ0YACgkQvJuQZxSWSsiDAwCglJS9/juQLe8asY3sG9fagbeo 2V4An0p5U6UHGI1KXoe2qQvURX5E5BZo =Yy0J -----END PGP SIGNATURE-----
В списке pgsql-sql по дате отправления: