HASH function as a Uniqe number generator
Hi
We like to use Vertica HASH() function, for generating numbers on top of scripts , did HASH function gurenty Uniqes ? so two diffrent string will never have the same same hash number ?.
We like to use Vertica HASH() function, for generating numbers on top of scripts , did HASH function gurenty Uniqes ? so two diffrent string will never have the same same hash number ?.
0
Comments
No. So uniqueness not guaranteed, in sequence 0 <= Seq <= 2^63 + 1 must be exists at least one duplicate.
Pigeonhole principle: http://en.wikipedia.org/wiki/Pigeonhole_principle