hashtext
I believe it's considered an internal function, and not one to rely
on. If you search the archives, you will find reports around a version
upgrade when it changed the output for a certain input and thus broke
yes. I did find that discussion, and a blog post by Peter E. about this breakage.
BUT...
then there is skytools ... using hashtext for various things, and the report:
describing it is fact roughly 40% faster then md5 AND is an integer, so
select sum(hastext(t.*::text)) as signature from datable t
as a fast way of comparing 2 replicated tables is really something to consider....
conclusion was that it's not documented because it's internal and
you're not supposed to use/rely on it.
My impression is that people are allready using it, relying their sharding on it, even building indexes on it.
So... I suggest we start documenting it. Even if there was a recommendation not to use it, people will get hurt anyway if their application rely on it and it breaks.
Could I persuade?
Harald
--
PostgreSQL Training, Services and Support
2ndQuadrant Deutschland GmbH
GF: Harald Armin Massa
Amtsgericht Stuttgart, HRB 736399