Re: [GENERAL] length of return value of to_char()

2011-05-21 Thread Seb
On Sat, 21 May 2011 02:12:13 -0400, Michael Glaesemann wrote: [...] > There's a preceeding space: [...] Thanks! Good to have quote_literal in mind for this. -- Seb -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http://www.postg

Re: [GENERAL] length of return value of to_char()

2011-05-20 Thread Michael Glaesemann
On May 21, 2011, at 2:00, Seb wrote: > Hi, > > I thought this should be equal to 4: > > # SELECT length(to_char(11, '0999')); > length > > 5 > (1 row) > > but the string returned by the to_char() call is 0011 (length 4). What > am I missing? There's a preceeding space: postgr

[GENERAL] length of return value of to_char()

2011-05-20 Thread Seb
Hi, I thought this should be equal to 4: # SELECT length(to_char(11, '0999')); length 5 (1 row) but the string returned by the to_char() call is 0011 (length 4). What am I missing? Thanks, -- Seb -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To mak