Re: [GENERAL] Number Conversion Function

2009-04-13 Thread Merlin Moncure
On Mon, Apr 13, 2009 at 2:40 PM, Tino Wildenhain wrote: > justin wrote: >> >> >> Tom Lane wrote: >>> >>> Tino Wildenhain writes: >>> I would not recommend to do this within the database. Thats typical a job for your presentation layer. >>> >>> ... but having said that, I think

Re: [GENERAL] Number Conversion Function

2009-04-13 Thread justin
Tino Wildenhain wrote: justin wrote: I disagree the database is the wrong place, there are cases it makes sense. Which cases would that be? Regards Tino Report engines that don't have this ability . I use for check writing. To come think, I don't know of UI framework or report engine

Re: [GENERAL] Number Conversion Function

2009-04-13 Thread Tino Wildenhain
justin wrote: Tom Lane wrote: Tino Wildenhain writes: I would not recommend to do this within the database. Thats typical a job for your presentation layer. ... but having said that, I think the "money" datatype has a function for this. Whether that's of any use to you I dunno; mo

Re: [GENERAL] Number Conversion Function

2009-04-07 Thread justin
Tom Lane wrote: Tino Wildenhain writes: I would not recommend to do this within the database. Thats typical a job for your presentation layer. ... but having said that, I think the "money" datatype has a function for this. Whether that's of any use to you I dunno; mo

Re: [GENERAL] Number Conversion Function

2009-04-06 Thread Alvaro Herrera
Albe Laurenz wrote: > Abdul Rehman wrote: > > Can any body help me in converting numeric values into words > > via postgres function: i.e. 313 to THREE HUNDRED THREE > > Here is a little PL/pgSQL function that should do what you > want for numbers < 1. > It should be easy to extend if

Re: [GENERAL] Number Conversion Function

2009-04-06 Thread Albe Laurenz
Abdul Rehman wrote: > Can any body help me in converting numeric values into words > via postgres function: i.e. 313 to THREE HUNDRED THREE Here is a little PL/pgSQL function that should do what you want for numbers < 1. It should be easy to extend if you switch to bigint and decide i

Re: [GENERAL] Number Conversion Function

2009-04-06 Thread Tom Lane
Tino Wildenhain writes: > Abdul Rehman wrote: >> Can any body help me in converting numeric values into words via >> postgres function: i.e. 313 to THREE HUNDRED THREE > I would not recommend to do this within the database. Thats typical > a job for your presentation layer. ... but having said

Re: [GENERAL] Number Conversion Function

2009-04-06 Thread Tino Wildenhain
Abdul Rehman wrote: Hi all, Can any body help me in converting numeric values into words via postgres function: i.e. 313 to THREE HUNDRED THREE I would not recommend to do this within the database. Thats typical a job for your presentation layer. Regards Tino -- Sent via pgsql-general maili

Re: [GENERAL] Number Conversion Function

2009-04-06 Thread A. Kretschmer
In response to Abdul Rehman : > Hi all, > > Can any body help me in converting numeric values into words via postgres > function: i.e. 313 to THREE HUNDRED THREE You can use the PERL-Module from http://search.cpan.org/~sburke/Lingua-EN-Numbers-1.01/lib/Lingua/EN/Numbers.pm and plperlU Andreas -

[GENERAL] Number Conversion Function

2009-04-06 Thread Abdul Rehman
Hi all, Can any body help me in converting numeric values into words via postgres function: i.e. 313 to THREE HUNDRED THREE Regards, Abdul Rehman.