Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.server -> Re: Is there a way to use "COLUMN FORMAT" in a Pro*C/C++ app?
On Apr 2, 7:50 am, "Ramon F Herrera" <r..._at_conexus.net> wrote:
> My application has some SQL statements like this:
>
> SELECT
> to_char(amount1, '99,999,990.00'), \
> to_char(amount2, '99,999,990.00'), \
> to_char(amount3, '99,999,990.00'), \
> to_char(amount4, '99,999,990.00'),
> [...]
>
> Is that the only way to format real numbers from a precompiler
> application?
>
> The command "COLUMN FORMAT" seems to work only from SQL*Plus.
>
> TIA,
>
> -Ramon F Herrera
The COLUMN command is a sql*plus command, it isn't a SQL command. So
yes, it is the only way.
Obviously you could define the format as a string constant, but it
seems you prefer hardcoding and maintenance nightmares.
-- Sybrand Bakker Senior Oracle DBAReceived on Mon Apr 02 2007 - 02:41:00 CDT
![]() |
![]() |