Binary vs Integer - as primary key?
I was wondering if there are any obvious pros and cons one should be aware about, while choosing to use a Binary type as a primary key, while being RA开发者_运维问答NDOMIZED.
Which means, new inserts will have random 4 bytes as their PK - versus having a sequence of type Integer?
I'm using MySQL/MyISAM.
Thanks, Doori Bar
If the primary key isn't sequential then insert performance for a clustered index will not be very good. It has to rearrange the index for almost every insert.
精彩评论