Outbound Link Summary:
16 years ago
p3k dots

from the embarassing technical confessions department.

just yesterday i learnt that the value in brackets of mysql's numeric type definitions – e.g. mediumint(10) – does not specify the size of the numeric value at all.

a "medium integer" always remains medium (3 bytes large, that is) no matter whether i write mediumint(42) or mediumint(255).

the number in brackets only defines little visual sugar when displaying result sets in ascii mode ("display width"). matt thommes explains it quite nicely.