I did a simple test comparing:
-
char(32)(96 bytes) -
binary(16)(16 bytes) -
bigint(20)(8 bytes)
I ran a basic inner joining query, counting the matching rows on my local machine. Table A had 426,252 rows and table B had 74,226 rows. All rows from Table B had a match in table A.
The binary data type was 2.3 times faster than char. The bigint data type was 1.5 times faster than binary and 3.5 times faster than char.
This is in line with @hanson statement, proving that integers is significantly faster in e.g. JOIN queries. However, the execution times for simple lookups with indexes remain the same.