Re: Accessing 2 different databases in the same query ?

Поиск
Список
Период
Сортировка
От Joe Conway
Тема Re: Accessing 2 different databases in the same query ?
Дата
Msg-id 3EDB8139.6000900@joeconway.com
обсуждение исходный текст
Ответ на Re: Accessing 2 different databases in the same query ?  (Nagib Abi Fadel <nagib_postgres@yahoo.com>)
Список pgsql-general
Nagib Abi Fadel wrote:
> Well actually the 2 databases are on the same machine, so i wanted to
> know if  using the dblink for accessing 2 tables each one in a
> different database will dramatically slow down the query (specially
> if it's a join query), Comparing to a query on 2 tables on the same
> database. If it's the case i would consider replacing the 2 databases
> with one database, but does this have any disadvantage does it make
> queries slower if the database grow in size ???
>

dblink is using a client library and is therefore certainly slower than
backend heap access.

Whether the slowdown is "dramatic" or not, is a dependent on *your*
definition of dramatic, and the specifics of what you are trying to do.
I'd suggest you try it and find out.

If it's too slow to meet your needs, and you are able to combine the two
databases into two schemas of one database, then do that instead.

Joe


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

Предыдущее
От: "scott.marlowe"
Дата:
Сообщение: Re: The best
Следующее
От: "Sean Mullen"
Дата:
Сообщение: array [] vs {}