pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: L.V.Boldareva <me@pierro.dds.nl>
To: pgsql-sql@postgresql.org
Subject: Re: CREATE table1 FROM table2
Date: Mon, 23 Jun 2003 17:26:06 +0200
Message-ID: <98966401561.20030623172606@pierro.dds.nl> (raw)
In-Reply-To: <Pine.LNX.4.44.0306171831230.20339-100000@emo.org.tr>
References: <Pine.LNX.4.44.0306171831230.20339-100000@emo.org.tr>

Hello!

many people posted their answer to this simple question. however,
neither
CREATE TABLE AS
nor
SELECT INTO

do not take care about keys and triggers, etc.

The commands above only copy the structure of the table, and the data.
Are there any workarounds fr copying the table as a whole object?

thanks,
Mila


> Hi,

> On 17 Jun 2003, Rado Petrik wrote:

>> How I create table1 from other table2 . 

> CREATE TABLE table1 AS SELECT * FROM table2;

> will work.

> Regards,




view thread (8+ messages)  latest in thread

Message-ID: <98966401561.20030623172606@pierro.dds.nl>
Permalink:  ../98966401561.20030623172606@pierro.dds.nl/
Also on:    postgresql.org/message-id/98966401561.20030623172606@pierro.dds.nl

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: me@pierro.dds.nl
  Subject: Re: CREATE table1 FROM table2
  In-Reply-To: <98966401561.20030623172606@pierro.dds.nl>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox