Re: Question about foreign key

Поиск
Список
Период
Сортировка
От Christoph Dalitz
Тема Re: Question about foreign key
Дата
Msg-id 20021107155258.75f63524.christoph.dalitz@hs-niederrhein.de
обсуждение исходный текст
Ответ на Question about foreign key  (Terence Leung <tcmleung@yahoo.com>)
Список pgsql-general
> Date: Wed, 6 Nov 2002 03:49:49 -0800 (PST)
> From: Terence Leung <tcmleung@yahoo.com>
>
>     Hi, I am Terence and using Postgresql 7.0 in linux
>
You should consider an upgrade to 7.2 or (if you can wait some months)
to 7.3. These versions are *strong* improvements.

>  "select login_name,quest_name FROM sys_quest_list
> JOIN sys_user ON owner_id=sys_user.id"
>
> Can the added foreign key improve the above sql
> performance so that it can search faster
>
No.

>   or the foreign key can only maintain the data
> integrity but cannot make the search faster?
>
Yes.

For better search performance, do a CREATE INDEX and don't forget to
ANALYZE the table.

Christoph Dalitz

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: parser error: 9223372036854775807
Следующее
От: "Shridhar Daithankar"
Дата:
Сообщение: Re: [HACKERS] Database replication... - Mission Critica