Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: Are these "features" or bugs?
A copy of this was sent to Walter Dnes <waltdnes_at_waltdnes.org>
(if that email address didn't require changing)
On Sat, 04 Dec 1999 01:49:55 -0500, you wrote:
> 1) The PL/SQL output procedure DBMS_OUTPUT.PUT_LINE() appears to
>do an implicit LTRIM() on output. E.g. the string ' XX' is output
>as 'XX'. This really mucks up attempts to output reports in neat
>columns. I've resorted to putting leading dots at the beginning
>of the line to force proper alignment. Is there such an animal as
>a "non-breaking-space" ?
> BTW, lines consisting entirely of spaces don't get printed at all.
>Not even a line feed!
>
yes, this is the way it works. I use a chr(9) (tab) myself.
Consider using UTL_FILE to create nicely formatted reports (you can write directly to disk this way)
> 2) TO_CHAR(<number>, '99') and any variant thereof appears to
>return a leading space in addition to the columns specified. Again,
>not knowing this creates mucho problems when trying to line up output
>in columns.
this is the correct behaviour as well (consider -- number can be negative, the space is for the sign).
use "to_char( x, 'fm99' )" to get it without blanks.
--
See http://osi.oracle.com/~tkyte/ for my columns 'Digging-in to Oracle8i'...
Current article is "Part I of V, Autonomous Transactions" updated June 21'st
Thomas Kyte tkyte_at_us.oracle.com Oracle Service Industries Reston, VA USA
Opinions are mine and do not necessarily reflect those of Oracle Corporation Received on Sat Dec 04 1999 - 07:58:35 CST
![]() |
![]() |