Convert number to string

From: "Hengky Liwandouw" <hengkyliwandouw(at)gmail(dot)com>
To: <pgsql-general(at)postgresql(dot)org>
Subject: Convert number to string
Date: 2015-09-24 08:09:35
Message-ID: 000601d0f6a0$5bf61ac0$13e25040$@com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi,

I don't have any idea how can I use postgres function to convert series of
number (currency) to my own string.

My string : F G H I J K L M N as the replacement for number : 1 2 3
4 5 6 7 8 9

Dozens = O

Hundreds = P

Thousands = C

Ten thousands = B

So.

200 = GP

2000 = GC

1150 = FFJO

30000 = HB

Any idea ?

Thanks In advance

---
This email has been checked for viruses by Avast antivirus software.
https://www.avast.com/antivirus

Responses

Browse pgsql-general by date

  From Date Subject
Next Message John R Pierce 2015-09-24 08:16:26 Re: Convert number to string
Previous Message David Rowley 2015-09-24 05:04:15 Re: Automatically Updatable Foreign Key Views