Re: [GENERAL] Function in psql to Compare two numbers and return the bigger value

2007-02-13 Thread Steve Wampler
Emi Lu wrote: > Does it mean it is not allowed to use "select greatest(12.6,3.8)" ? It may mean you're not running 8.1? Here's what I get: --- ->psql Welcome to psql 8.1.4, the PostgreSQL interactive terminal. Type: \copyright for distribu

Re: [GENERAL] Function in psql to Compare two numbers and return the bigger value

2007-02-13 Thread Emi Lu
Emi Lu wrote: I am looking for a psql method to get the bigger value of two numbers. For example, methodName(12.6, 3.8) select greatest(12.6,3.8); It does not work for me, select greatest(12.6,3.8); ERROR: function greatest(numeric, numeric) does not exist HINT: No function matches the

Re: [GENERAL] Function in psql to Compare two numbers and return the bigger value

2007-02-13 Thread Emi Lu
I am looking for a psql method to get the bigger value of two numbers. For example, methodName(12.6, 3.8) select greatest(12.6,3.8); It does not work for me, select greatest(12.6,3.8); ERROR: function greatest(numeric, numeric) does not exist HINT: No function matches the given name and

Re: [GENERAL] Function in psql to Compare two numbers and return the bigger value

2007-02-13 Thread Bricklen Anderson
Emi Lu wrote: HEllo, I am looking for a psql method to get the bigger value of two numbers. For example, methodName(12.6, 3.8) select greatest(12.6,3.8); ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropr

Re: [GENERAL] Function in psql to Compare two numbers and return the bigger value

2007-02-13 Thread Adam Rich
You want GREATEST() -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emi Lu Sent: Tuesday, February 13, 2007 12:37 PM To: pgsql-general@postgresql.org Subject: [GENERAL