Re: Equivalent to "use database" in postgre

Поиск
Список
Период
Сортировка
От Craig Ringer
Тема Re: Equivalent to "use database" in postgre
Дата
Msg-id 4C24C4CA.7060206@postnewspapers.com.au
обсуждение исходный текст
Ответ на Equivalent to "use database" in postgre  (javijava <welove.e.music@gmail.com>)
Список pgsql-general
On 25/06/10 19:10, javijava wrote:
>
> Hi,
>
> i'm newby in postgre sql world.
>
> i need to know how to do a simple script  that create a database,the y
> select it (in other languajes using USE) and after create tables with this
> database.

http://wiki.postgresql.org/wiki/FAQ

http://www.coderholic.com/postgresql-for-mysql-users/

Most MySQL users misunderstand "databases" in postgresql. The closest
equivalent in PostgreSQL to a MySQL "database" is a PostgreSQL "schema".
If you expect to be able to run queries that use data from multiple
"databases" you really want to use schema.

See the help for the "psql" command for basic scripting, including the
"\c" command to connect to another DB. For help on an SQL command, run
"\h COMMANDNAME" in psql, or read the manual for that command.

--
Craig Ringer

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

Предыдущее
От: Ozz Nixon
Дата:
Сообщение: Re: Equivalent to "use database" in postgre
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Need Some Recent Information on the Differences between Postgres and MySql