Re: How to overload POSITION

Поиск
Список
Период
Сортировка
От Troels Arvin
Тема Re: How to overload POSITION
Дата
Msg-id pan.2004.11.16.21.12.53.350397@arvin.dk
обсуждение исходный текст
Ответ на How to overload POSITION  (Troels Arvin <troels@arvin.dk>)
Список pgsql-general
On Tue, 16 Nov 2004 15:56:00 -0500, Tom Lane wrote:

> [... cut advice ...]

Thanks.

> How wedded are you to being able to say "IN"?

It's only a would-be-nice-to-have.

My dnaseq data type exploits the fact that DNA sequences are made from a
very small alphabet (four characters), so strings can be compressed/packed
4:1 while still being directly usable. A POSITION(dnaseq IN dnaseq) would
mean that the dnaseq-values don't have to be converted to text before
being searched.

But I can live with my existing DNASEQ_POSITION(dnaseq,dnaseq) solution
(which works directly on the dnaseq packed strings).

(I will also try to create a specialized index for long strings, hopefully
using some substring array algorithmics - but that's another story.)

--
Greetings from Troels Arvin, Copenhagen, Denmark


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: How to overload POSITION
Следующее
От: Timothy Perrigo
Дата:
Сообщение: Re: question about temp table in function