Re: [GENERAL] 50 MB Table

Поиск
Список
Период
Сортировка
От JB
Тема Re: [GENERAL] 50 MB Table
Дата
Msg-id 38C596E5.8588B319@kw.igs.net
обсуждение исходный текст
Ответ на 50 MB Table  (JB <jimbag@kw.igs.net>)
Список pgsql-general
I've posted this as a suggestion to the HACKERS list. I'd love to make a
patch but just don't have the time right now to sort through the code.

cheers
jim

Bruce Bantos wrote:
>
> > I've been shuffling thru the 'LIKE' code in pg, but whilst perusing, it
> > occurred to me that I could use a function for this thing. Since i'm
> > only looking at the first part of the string I use...
> >
> > SELECT * FROM info WHERE substring(street_name from 1 to 4) = 'MAIN'
> >
> > ...and the query completes in under 2 secs. Stupidly obvious now but I
> > thought I would share this blinding insight with the list ;)
>
> It was not so obvious to me. I was struggling with the same thing. This is a
> good workaround for the case of "searchstring%". I wonder if the LIKE code
> could be enhanced to perform the query in the same way.
>
--
If everything is coming your way then you're in the wrong lane.

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

Предыдущее
От: Bruce Momjian
Дата:
Сообщение: Re: [GENERAL] binary data & LOBs
Следующее
От: Mona Kaur
Дата:
Сообщение: Postgres question