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

Re: DATABASE CLONNING

From: Alan Hodgson <ahodgson(at)simkin(dot)ca>
To: pgsql-novice(at)postgresql(dot)org
Subject: Re: DATABASE CLONNING
Date: 2008-06-11 16:28:51
Message-ID: 200806110928.51973@hal.medialogik.com (view raw or flat)
Thread:
Lists: pgsql-novice
On Wednesday 11 June 2008, "JORGE MALDONADO" <jorgemal1960(at)gmail(dot)com> wrote:
> I am developing an application in which I need to create several equal
> databases based on one that I will take as standard. What I mean is that
> I will create one basic empty complete database (including table,
> constrains, indexes, etc.) and from here I need to clone other databases
> which will be part of the production application.
> Is it possible to do it ???

You can use an existing database as a template when creating new databases 
(as, indeed, template1 is used by default). See the -T option to createdb.

-- 
Alan

In response to

pgsql-novice by date

Next:From: Ram RavichandranDate: 2008-06-13 20:13:03
Subject: combining multiple partial indices
Previous:From: Mark RobertsDate: 2008-06-11 16:18:39
Subject: Re: DATABASE CLONNING

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