Re: Sending function parametars within EXECUTE ''SELECT...

From: Mario Splivalo <mario(dot)splivalo(at)mobart(dot)hr>
To: pgsql-sql(at)postgresql(dot)org
Subject: Re: Sending function parametars within EXECUTE ''SELECT...
Date: 2005-09-29 06:30:31
Message-ID: 1127975432.8131.0.camel@localhost.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Wed, 2005-09-28 at 10:01 -0700, codeWarrior wrote:
> >
> > ---------------------------(end of
broadcast)---------------------------
> > TIP 5: don't forget to increase your free space map settings
> >
>
> FOR rec IN EXECUTE ''SELECT COUNT(col1) AS num FROM tmpTbl WHERE col2
= " ||
> aBid || '' LOOP
>

Huh! :) Seems so obvious now :)

Is there a way to assing variable a value returned from query that
accesses the temporary table in a way you explained above?

For instance, I can do:

myValue := col2 FROM tmpTbl WHERE someValue = somethingElse...

But then I encounter the problem with temp tables. Can I do EXECUTE'd
SELECT like you explained above? Or I need to do 'widdleing' with FOR
like explained above?

Mario

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Stewart Ben (RBAU/EQS4) * 2005-09-29 06:36:43 Re: Sending function parametars within EXECUTE ''SELECT...
Previous Message Kenneth Gonsalves 2005-09-29 06:27:58 Re: unsubscribe