Alvaro Herrera wrote:
On Wed, Oct 05, 2005 at 10:04:10PM -0500, David Durham wrote:

is there a syntax that would look something like:

create table newTable like oldTable without indexes || records ||
constraints with indexes || records || constraints

built into postgres?

What do you want to do with it? If I understand what you want to do, it
is supported as long as you use ; in place of your ||.

Well, I should say that the with and without should probably be mutually
exclusive. I don't know, haven't thought about it that much, but I find
myself creating a lot of the same table over and over from time to time
as I try to analyze some data. Would be nice to say, hey, create a copy
of this table with indexes and possibly records and constraints. Or
just a bare copy or something like that, but have a lot of different
options for this kind of thing.

- Dave

Search Discussions

Discussion Posts


Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 4 of 4 | next ›
Discussion Overview
grouppgsql-admin @
postedOct 6, '05 at 3:04a
activeOct 7, '05 at 2:48p



site design / logo © 2022 Grokbase