Re: "SELECT IN" Still Broken in 7.4b

Поиск
Список
Период
Сортировка
От Joe Conway
Тема Re: "SELECT IN" Still Broken in 7.4b
Дата
Msg-id 3F43CAF1.9050405@joeconway.com
обсуждение исходный текст
Ответ на Re: "SELECT IN" Still Broken in 7.4b  (Mike Winter <mike.winter@frontlogic.com>)
Список pgsql-sql
Mike Winter wrote:
> On Wed, 20 Aug 2003, Rod Taylor wrote:
> 
>>Ensure your IN list is unique.  You might find better times by through
>>an indexed temp table.
> 
> That is what I ended up doing, but it's not a very elegant solution.
> MySQL does queries of this type orders of magnitudes faster than Postgres
> on large value lists, although I have no specific algorithmic solutions to
> offer for how to make it faster.  I don't believe making the IN lists
> unique has any affect on performance.
> 

I have no idea whether it will be better or worse performance, but in 
7.4 you could do:

select blah from foo where id = any (ARRAY[list_of_literals]);

Joe




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

Предыдущее
От: Mike Winter
Дата:
Сообщение: Re: "SELECT IN" Still Broken in 7.4b
Следующее
От: "Aasmund Midttun Godal"
Дата:
Сообщение: Re: Before/After Trigger User Switching