Greetings,
I have a plpython function that returns a set of records. I loop over them
to insert them into a temp table created by another function.
I wanted to test
select into temp_eav_table (column) select a.column from tbl as a where
approach to see if it performs better than the loop.
The documentation for select into covers this and provides your alternatives.
http://www.postgresql.org/docs/9.2/interactive/sql-selectinto.html
David J.
On Dec 25, 2012, at 10:20, Seref Arikan serefari...@kurumsalteknoloji.com
wrote:
Greetings,
I have a plpython function that returns a
David,
Thanks for your response. However, I can't see my solution there. According
to documentation, select into is supposed to create a new table. Create
table as is offered as an alternative, but my table is already ready when
I execute the statement.
Maybe it is my lack of understanding, but I
SELECT INTO -- define a new table from the results of a query
If the table exists use:
INSERT INTO tbl (.) SELECT .
David J.
From: Seref Arikan [mailto:serefari...@kurumsalteknoloji.com]
Sent: Tuesday, December 25, 2012 10:52 AM
To: David Johnston
Cc: PG-General Mailing List
On 12/25/2012 07:20 AM, Seref Arikan wrote:
Greetings,
I have a plpython function that returns a set of records. I loop over
them to insert them into a temp table created by another function.
I wanted to test
select into temp_eav_table (column) select a.column from tbl as a where
approach to
Seref Arikan serefari...@kurumsalteknoloji.com writes:
I have a plpython function that returns a set of records.
Is that actually plpython, or plpgsql? Because what you're showing is
not legal syntax in either bare SQL or plpython, but it would act as
you're reporting in plpgsql:
SELECT INTO
Thanks Tom,
Following David's advice, I've used insert into syntax, but got hit with a
report of ambiguity of selected node.
The issue was discussed here:
http://archives.postgresql.org/pgsql-sql/2011-09/msg00059.php
The advice here: