one-off error in to_char formatting

From: "Erik Rijkers" <er(at)xs4all(dot)nl>
To: pgsql-hackers(at)postgresql(dot)org
Subject: one-off error in to_char formatting
Date: 2010-03-04 15:30:55
Message-ID: fdc101b06b1e7a981c0cd9c1116a6c37.squirrel@webmail.xs4all.nl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

ISTM this is a bug, no?

(9.0devel, cvs 2010.03.04 01:30)

replicas=# select length( to_char(1, '0') );
length
--------
2
(1 row)

There seems to be an erroneously prefixed space:

replicas=# select '>' || to_char(1, repeat('0',8)) || '<';
?column?
-------------
> 00000001<
(1 row)

replicas=# select version();
version
--------------------------------------------------------------------------------------------------
PostgreSQL 9.0devel-standby on x86_64-unknown-linux-gnu, compiled by GCC gcc (GCC) 4.4.3, 64-bit
(1 row)

Erik Rijkers

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2010-03-04 15:43:50 Re: Streaming replication and privilege
Previous Message Tom Lane 2010-03-04 15:27:25 Re: Repetition of warning message while REVOKE