Hash Function: MD5 or other?

Поиск
Список
Период
Сортировка
От Peter Fein
Тема Hash Function: MD5 or other?
Дата
Msg-id 20050613174959.6fb1df80@layout.pfein.org
обсуждение исходный текст
Ответы Re: Hash Function: MD5 or other?  (Shelby Cain <alyandon@yahoo.com>)
Re: Hash Function: MD5 or other?  (Alex Stapleton <alexs@advfn.com>)
Список pgsql-general
Hi-

I wanted to use a partially unique index (dependent on a flag) on a TEXT
column, but the index row size was too big for btrees.  See the thread
"index row size 2728 exceeds btree maximum, 2713" from the beginning of
this month for someone with a similar problem.  In it, someone suggests
indexing on a hash of the text.  I'm fine with this, as the texts in
question are similar enough to each other to make collisions unlikely
and a collision won't really cause any serious problems.

My question is: is the builtin MD5 appropriate for this use or should I
be using a function from pl/something?  Figures on collision rates would
be nice as well - the typical chunk of text is probably 1k-8k.

Thanks!

--
Peter Fein                 pfein@pobox.com                 773-575-0694

Basically, if you're not a utopianist, you're a schmuck. -J. Feldman

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

Предыдущее
От: "Jonah H. Harris"
Дата:
Сообщение: Re: [HACKERS] mirroring oracle database in pgsql
Следующее
От: Sean Davis
Дата:
Сообщение: Re: [HACKERS] mirroring oracle database in pgsql