On Tuesday 11 November 2003 02:16, Robert Creager wrote:
> When grilled further on (Mon, 10 Nov 2003 09:39:32 -0500),
>
> Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> confessed:
> > We recently decided we had to forbid foreign-key references from temp
> > tables to permanent tables because of this effect. I wonder whether
> > we won't end up forbidding temp tables as children of permanent tables
> > too.
>
> Forbidding temp tables that inherit? That would suck (as someone who uses
> them). Would there be an alternate method to easily create a temp table
> that is identical to another?
You can use LIKE clause in create table.
See http://developer.postgresql.org/docs/postgres/sql-createtable.html
HTH
Shridhar