Re: ip address data type

Поиск
Список
Период
Сортировка
От Steve Atkins
Тема Re: ip address data type
Дата
Msg-id AA27228F-6E88-4DB0-845C-D02F9B1FF4D9@blighty.com
обсуждение исходный текст
Ответ на ip address data type  ("Sriram Dandapani" <sdandapani@counterpane.com>)
Список pgsql-performance
On Apr 24, 2006, at 3:45 PM, Sriram Dandapani wrote:

> Hi
>
>
>
> I have queries that use like operators and regex patterns to
> determine if an ip address is internal or external (this is against
> a table with say 100 million distinct ip addresses).
>
>
>
> Does the inet data type offer comparison/search performance
> benefits over plain text for ip addresses..
It's probably better than text-based, but it's hard to be worse than
regex and like.

Depending on your exact needs http://pgfoundry.org/projects/ip4r/ may be
interesting, and I've also found pretty good behavior by mapping an IP
address onto a 2^31 offset integer.

Cheers,
   Steve

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

Предыдущее
От: "Jim C. Nasby"
Дата:
Сообщение: Re: ip address data type
Следующее
От: Mark Kirkwood
Дата:
Сообщение: Re: Hardware: HP StorageWorks MSA 1500