Re: to_hex leading zeroes

From: Scott Marlowe <scott(dot)marlowe(at)gmail(dot)com>
To: Pedro Doria Meunier <pdoria(at)netmadeira(dot)com>
Cc: Postgresql Mailing List <pgsql-general(at)postgresql(dot)org>
Subject: Re: to_hex leading zeroes
Date: 2009-03-15 14:11:15
Message-ID: dcc563d10903150711x7f848d84r46f9afdd4f7726e9@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Sun, Mar 15, 2009 at 6:47 AM, Pedro Doria Meunier
<pdoria(at)netmadeira(dot)com> wrote:
> Hi All,
>
> I'm in a bit of a pickle here with the to_hex function not returning leading
> zeroes ...
> For instance if I:
> SELECT to_hex(10);
>
> it returns 'a' not '0a' .

Have you looked at lpad()?

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Justin 2009-03-15 15:47:30 Re: [ask] Return Query
Previous Message Pedro Doria Meunier 2009-03-15 12:47:00 to_hex leading zeroes