Re: pgplsql, how to save row variable to a table row - Mailing list pgsql-general

From Sam Mason
Subject Re: pgplsql, how to save row variable to a table row
Date
Msg-id 20080326122614.GN6870@frubble.xen.chris-lamb.co.uk
Whole thread Raw
In response to Re: pgplsql, how to save row variable to a table row  ("josep porres" <jmporres@gmail.com>)
Responses Re: pgplsql, how to save row variable to a table row  (Raymond O'Donnell <rod@iol.ie>)
List pgsql-general
On Wed, Mar 26, 2008 at 01:14:07PM +0100, josep porres wrote:
> I've tried:
>
> EXECUTE 'INSERT INTO F2_TEMPFAC SELECT * FROM row_tempf';

I think that:

  INSERT INTO f2_tempfac
    SELECT (row_tempf).*;

should do what you want.  Unless you're doing something very fancy you
don't want the execute either.  You can just put normal SQL statements
in the code and they'll get run as normal, expanding variables when
needed.


  Sam

pgsql-general by date:

Previous
From: Raymond O'Donnell
Date:
Subject: Re: pgplsql, how to save row variable to a table row
Next
From: "Albe Laurenz"
Date:
Subject: Re: RULES and QUALIFICATION for INSERT