A question about differences between createdb and "create database"

Поиск
Список
Период
Сортировка
От Paul Vogel
Тема A question about differences between createdb and "create database"
Дата
Msg-id 43F0DD94.8080204@deadeyesoftware.com
обсуждение исходный текст
Ответы Re: A question about differences between createdb and "create database"  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-admin
I have a pg_dump of a database (without autocreation lines)  that I
tried loading by using the commands:
     createdb -T template0 -U postgres database; psql -U postgres
database < filename

 I couldn't get it to connect via ODBC.  But when I added the following
lines in the source file:

    CREATE DATABASE "database" WITH TEMPLATE = template0 ENCODING =
'SQL_ASCII';
    ALTER DATABASE "database" OWNER TO postgres;
    \connect "database"

And loaded it with the command "psql -U postgres template1 < fileanme"
the resultant database worked fine with ODBC.  So something is
apparently different between the command line "createdb" command and the
"create database" command.  Has anybody else run into this?  And if so,
are there any other problems I should be aware of?  Or did I miss an
option of the "createdb" line?

Thanks,
Paul
    PS - I'm currently running PostgreSQL 8.1.2 under Linux Fedora Core 2


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

Предыдущее
От: Tsirkin Evgeny
Дата:
Сообщение: Re: Ancient messages regurgitated into pgsql-admin, again
Следующее
От: Arnau Rebassa Villalonga
Дата:
Сообщение: Best filesystem