Skip site navigation (1) Skip section navigation (2)

CREATE TABLE AS ... EXECUTE

From: Alvaro Herrera Munoz <alvherre(at)dcc(dot)uchile(dot)cl>
To: pgsql-hackers(at)postgresql(dot)org
Subject: CREATE TABLE AS ... EXECUTE
Date: 2003-06-27 16:15:10
Message-ID: 20030627161510.GA6313@dcc.uchile.cl (view raw or flat)
Thread:
Lists: pgsql-hackers
Hackers,

Is there a way to create a table from a prepared statement?  CREATE TABLE AS
explicitly says you have to use a SELECT statement, and the SELECT INTO
syntax doesn't seem to allow the use of a prepared statement either.  I
don't see a way to use the prepared statement as a function nor as a "table"
(SELECT ... FROM EXECUTE)

Of course, the prepared statement is a SELECT statement.

Am I missing something, or it is supposed to be like this?  I don't _need_
this (I can use a regular SQL function), but...

-- 
Alvaro Herrera (<alvherre[(at)]dcc(dot)uchile(dot)cl>)
"Qu importan los aos?  Lo que realmente importa es comprobar que
a fin de cuentas la mejor edad de la vida es estar vivo"  (Mafalda)

Responses

pgsql-hackers by date

Next:From: Tom LaneDate: 2003-06-27 16:36:54
Subject: Re: CREATE TABLE AS ... EXECUTE
Previous:From: Tom LaneDate: 2003-06-27 16:12:17
Subject: Re: pg_guc

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group