Thanks Tom. I didn't know I needed a RETURN statement at the end. I assumed that the "return next" statement would be enough. It works fine now.
----------------------------------------------- Ignacio Colmenero Software Development Micotan Software Company Ltd. -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Tom Lane Sent: February 11, 2005 12:28 PM To: Ignacio Colmenero Cc: pgsql-general@postgresql.org Subject: Re: [GENERAL] ERROR: control reached end of function without RETURN "Ignacio Colmenero" <[EMAIL PROTECTED]> writes: > I get the error: ERROR: control reached end of function without RETURN > What can be wrong? You don't have a RETURN statement. regards, tom lane ---------------------------(end of broadcast)--------------------------- TIP 5: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq ---------------------------(end of broadcast)--------------------------- TIP 6: Have you searched our list archives? http://archives.postgresql.org