Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

dbms_utility.get_hash_value uniqueness?

Status
Not open for further replies.

wellster34

Programmer
Sep 4, 2001
113
CA
Oracle 8.1.7.4

I have two different character strings to get a hash key and I'm using the max which is 2 to the power of 30 (1073741824)

select
dbms_utility.get_hash_value(RTRIM('7235')||RTRIM('10041')||RTRIM('BS')||RTRIM('Cash & Cash Equivalents'),1,1073741824)
FROM DUAL

select
dbms_utility.get_hash_value(RTRIM('1520')||RTRIM('64507')||RTRIM('BS')||RTRIM('Capital & Retained Earnings'),1,1073741824)
FROM DUAL

They both return: 600891246

This is causing me data integrity issues since the same hash key can be duplicated.

Any ideas to create a unique number???
 


You could use a sequence [3eyes]


----------------------------------------------------------------------------
The person who says it can't be done should not interrupt the person doing it. -- Chinese proverb
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top