The x
in INT(x)
has nothing to do with space requirements or any other performance issues, it’s really just the display width. Generally setting the display widths to a reasonable value is mostly useful with the UNSIGNED ZEROFILL
option.
//INT(4) UNSIGNED ZEROFILL
0001
0002
...
0099
...
0999
...
9999
...
10000
//INT(2) UNSIGNED ZEROFILL
01
02
...
09
...
99
...
100
Without the UNSIGNED ZEROFILL
option the value will be left-padded with spaces to the appropriate display width.
//INT(4)
1
2
...
99
...
999
...
9999
...
10000
//INT(2)
1
2
...
9
...
99
...
100