Re: plpgsql at what point does the knowledge of the query come in? - Mailing list pgsql-general

From Henry Drexler
Subject Re: plpgsql at what point does the knowledge of the query come in?
Date
Msg-id CAAtgU9Q-vHuJpEAUT4Pg-MBiDo7foGiv1c8mSwLNyaq+ZTXu_w@mail.gmail.com
Whole thread Raw
In response to Re: plpgsql at what point does the knowledge of the query come in?  (Raymond O'Donnell <rod@iol.ie>)
Responses Re: plpgsql at what point does the knowledge of the query come in?
List pgsql-general
On Thu, Oct 20, 2011 at 4:57 PM, Raymond O'Donnell <rod@iol.ie> wrote:

Not sure what you mean by the above... that statement only gets executed
once, so the value of nnlength doesn't change.

Ray.


doesn't the function get executed once for each row in the query?
so in the below example
threeee will match threee
but fiveu will not match five because it has not reset  nnlength := length(newnode); to measure the length of fiveu but is retaining the length of threeee

is it possible to get nnlength := length(newnode); to reset for each new row/node in the query?

pgsql-general by date:

Previous
From: "J.V."
Date:
Subject: Re: how to disable all pkey/fkey constraints globally
Next
From: Henry Drexler
Date:
Subject: Re: plpgsql at what point does the knowledge of the query come in?