Re: Need help using function - Mailing list pgsql-general

From Bob Pawley
Subject Re: Need help using function
Date
Msg-id 8C56ED8B07674A548FA457FEC4A21F76@desktop
Whole thread Raw
In response to Need help using function  ("Bob Pawley" <rjpawley@shaw.ca>)
Responses Re: Need help using function
List pgsql-general
That worked.

However, perhaps I don't understand the idea of a function.

If the , in this case ('1'),  was in fact an unknown variable what would the
return be?

Bob
----- Original Message -----
From: "John R Pierce" <pierce@hogranch.com>
To: "Bob Pawley" <rjpawley@shaw.ca>; <pgsql-general@postgresql.org>
Sent: Friday, June 26, 2009 10:15 AM
Subject: Re: [GENERAL] Need help using function


> Bob Pawley wrote:
>> Hi
>>  I want to try using functions but I am having trouble understanding
>> return.
>>  ...
>>  The error message - "control reached end of function without RETURN"
>>  I have attempted adding - Return integer; to the end of the function
>> with no success.
>>
>
>
> I'd try adding
>     RETURN 1;  or similar,  before the END;
>
>


pgsql-general by date:

Previous
From: John R Pierce
Date:
Subject: Re: Need help using function
Next
From: "Jonah H. Harris"
Date:
Subject: Re: Need help using function