Steve Northamer writes:
> So my questions are: 1) How do we cause the paymentcalc function to be
> executed only once?
In recent versions, I think marking it volatile would be sufficient.
regards, tom lane
--
Sent via pgsql-sql mailing list (pgsql-sql@postgresql.org)
> So my questions are: 1) How do we cause the paymentcalc function to be
> executed only once? and 2) How do we call a table returning function with
> inputs from a table?
>
> Thank you very much!
>
> Steve
>
WITH func AS (
SELECT FUNC(...) AS func_result FROM ...
)
SELECT (func.func_re
We have a plpgsql function called paymentcalc, which calculates the
payment necessary to pay off a loan. It's defined like this:
CREATE OR REPLACE FUNCTION paymentcalc(IN amount numeric, IN
interestrate numeric, IN termmonths integer, IN paymentfreq integer, IN
dueday1 integer, IN dueday2 i
On 2011-09-29, Péter Szabó wrote:
> users_has_cards.auctions + users_has_cards.decks never can be higher
> then users_has_cards.total. It should be also granted that
> users_has_cards.total - users_has_cards.auctions number of cards from
> a specific type can be in any decks.
>
> The deck assembl