Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL

От: Andrew Sullivan
Тема: Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL
Дата: ,
Msg-id: 20030714114424.GH24166@libertyrms.info
(см: обсуждение, исходный текст)
Ответ на: Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  ("Balazs Wellisch")
Список: pgsql-performance

Скрыть дерево обсуждения

Pgsql - Red Hat Linux - VS MySQL VS MSSQL  ("Balazs Wellisch", )
 Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  (Shridhar Daithankar, )
 Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  (Joe Conway, )
 Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  ("Balazs Wellisch", )
 Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  ("Balazs Wellisch", )
  Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  (Andrew Sullivan, )
 Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  ("Balazs Wellisch", )
  Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  ("Jim C. Nasby", )
  Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  (Shridhar Daithankar, )
  Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  (Andrew Sullivan, )
 Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  ("Balazs Wellisch", )
  Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  (Joe Conway, )
 Re: Pgsql - Red Hat Linux - VS MySQL VS MSSQL  (Paul Thomas, )

On Sun, Jul 13, 2003 at 12:42:29PM -0700, Balazs Wellisch wrote:
> > On Sun, 2003-07-13 at 01:35, Balazs Wellisch wrote:

> > Note that I've read a couple of times from Tom Lane (one of the
> > core team) that FKs are a serous performance drag, so I'd drop
> > them after the s/w has been in production long enough to work
> > out the kinks.
> >
>
> That's interesting, I didn't know that. Any idea how much of a performance
> drag we're talking about?

Foreign keys in any database are going to cost you something, because
they require a lookup in other tables.

The big hit from FKs in PostgreSQL used to be that they caused
deadlocks in older versions.  I _think_ this is fixed by default in
7.3.3; if not, there's a patch floating around for the problem.  The
repair is definitely in 7.4.

That said, if speed is your goal, FKs are always going to be a cost
for you.  OTOH, people who try to handle this sort of thing in the
application come to regret it.  You probably want to look somewhere
else to solve your performance difficulties from FKs.

A

--
----
Andrew Sullivan                         204-4141 Yonge Street
Liberty RMS                           Toronto, Ontario Canada
<>                              M2P 2A8
                                         +1 416 646 3304 x110



В списке pgsql-performance по дате сообщения:

От: "Stephen Howie"
Дата:
Сообщение: Re: Tunning FreeeBSD and PostgreSQL
От: "Nick Fankhauser"
Дата:
Сообщение: Sanity check requested