You want GREATEST() <http://www.postgresql.org/docs/8.2/interactive/functions-conditional.ht ml#AEN13140>
-----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] Function in psql to Compare two numbers and return the bigger value HEllo, I am looking for a psql method to get the bigger value of two numbers. For example, methodName(12.6, 3.8) Will return 12.6 Thanks! ---------------------------(end of broadcast)--------------------------- TIP 6: explain analyze is your friend ---------------------------(end of broadcast)--------------------------- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED] so that your message can get through to the mailing list cleanly