> I think I have not understood some elementary things of the to_char function
> in pgsql7.1.2. I only get back a mask instead of a formatted string.
> I tried the following in psql:
> SPS=> select to_char(45145, '9.999,99');
> (1 row)
The number will not fit into the field you have defined, so it is filled
with hash marks to indicate overflow.
If your locale is not set up to recognize "european style" numbers, then
in this case you have defined a formatting string which allows only
numbers less than 10. If you are set up to recognize european formatting
(I'm not familiar with this for to_char(); see the docs) then you have
defined a formatting string with allows only numbers less than 9999,
which still won't hold the number you are asking it to format for you.
Try to_char(45145, '99,999.99') and to_char(45145, '99.999,99'); one of
them will work.
In response to
pgsql-general by date
|Next:||From: Frank Schafer||Date: 2002-01-29 13:25:43|
|Subject: Re: unique & update|
|Previous:||From: Frank Schafer||Date: 2002-01-29 12:41:16|
|Subject: Re: Multibyte encoding vs. SQL_ASCII and European|