Kristis Makris wrote:
>
> Creating the temporary table first, and then inserting into it seems to
> be a *somehow* functional workaround. However, the function cannot be
> called again a second time during the same session, since the temporary
> table already exists. Is there a way a table can be created truly
> temporary, existing only within the scope of a plpgsql function?
You could drop the temporary table at the end of the function, or do you
need something more than that?
- Richard Huxton