I am looking for advice for either finding or creating a hash algorithm to be used in .Net C#.
I have a collection of columns from a DB. The combination of columns across the table are guaranteed to produce unique strings.
Consider:
String Column1 = "StringA";
String Column2 = "StringB";
String Column3 = "StringC";
I concatenate the columns into a single string:
String ColumnKey = Column1 + Column2 + Column3;
Currently I'm using the built in .Net C# hash function from the string class.
int hashKey = ColumnKey.GetHashCode();
After doing some reading, it's my understanding that (although the probability is quite low) this algorithm does not guarantee uniqueness. It is also my understanding that this function could produce different results for the same string across different versions of the .Net Framework.
I am looking for another hash algorithm to use that would guarantee uniqueness and produce consistent results across different versions of .Net.
Can someone help get me started in the right direction?