Page is a not externally linkable
brotherhood_of_LAN - 10:39 pm on Aug 3, 2011 (gmt 0)
[edited by: brotherhood_of_LAN at 10:43 pm (utc) on Aug 3, 2011]
Indeed, I've never considered 1000 byte keys in practice, even if it's multi-byte text encoding...
You could probably get away with a 16 byte PRIMARY key by adding a BINARY(16) column for MD5 values.
INSERT IGNORE tablename (hash,term,url) VALUES (UNHEX(MD5('$term$url')),'$term','$url') ON DUPLICATE KEY UPDATE countercolumn = countercolumn + 1
// added
If you were to use MD5, you'd probably want to turn the $term URL to lowercase if case is unimportant for that field, as it would generate separate MD5's for lower and upper case.