Re: schema creation during initdb

Поиск
Список
Период
Сортировка
От Heikki Linnakangas
Тема Re: schema creation during initdb
Дата
Msg-id 4625EDD0.4000300@enterprisedb.com
обсуждение исходный текст
Ответ на Re: schema creation during initdb  ("sharath kumar" <k.sharat@gmail.com>)
Список pgsql-hackers
sharath kumar wrote:
> Sorry i have put the question wrongly. I wanted to ask if we can create a
> schema during createdb time so that i have to hide the following from the
> user.
> psql -c 'create schema foo' mytemplate
> psql -c 'create table foo.bar ...' mytemplate
> Whenever a user runs createdb command, the above schema and table should be
> created automatically.

You should create a template database with the schema and the tables you 
want. See chapter "19.3. Template Databases" in the user manual:

http://www.postgresql.org/docs/8.2/interactive/manage-ag-templatedbs.html

--   Heikki Linnakangas  EnterpriseDB   http://www.enterprisedb.com


В списке pgsql-hackers по дате отправления:

Предыдущее
От: "sharath kumar"
Дата:
Сообщение: Re: schema creation during initdb
Следующее
От: NikhilS
Дата:
Сообщение: Re: schema creation during initdb