Re: Advice with an insert query - Mailing list pgsql-sql

From Thomas Kellerer
Subject Re: Advice with an insert query
Date
Msg-id kosqgh$rqj$1@ger.gmane.org
Whole thread Raw
In response to Advice with an insert query  (JORGE MALDONADO <jorgemal1960@gmail.com>)
List pgsql-sql
JORGE MALDONADO, 07.06.2013 15:58:
> I need to insert records into a table where one value is fixed and 2 values come from a SELECT query, something like
thefollowing example:
 
> 
> INSERT INTO table1 fld1, fld2, fl3
> VALUES value1, (SELECT fldx, fldy FROM table2)
> 
> Is this valid?
> 
> Respectfully,
> Jorge Maldonado


INSERT INTO table1 (fld1, fld2, fl3)
SELECT value1, fldx, fldy 
FROM table2






pgsql-sql by date:

Previous
From: Oliver d'Azevedo Cristina
Date:
Subject: Re: Advice with an insert query
Next
From: rawi
Date:
Subject: Index Usage and Running Times by FullTextSearch with prefix matching