TINTYINT and column size

Does TINYINT(1) work to limit the column’s size or is it exactly like INT(11) which doesn’t do anything but determine how MYSQL should display the data?

there are two different concepts here

  1. TINYINT versus INTEGER determines how large a number can be stored

  2. the number in parentheses is used for display purpose only (see ZEROFILL)

Thanks, I realized (1) but see how it was ambiguous in the question. (2) is what I was after. I thought that by setting TINYINT to TINYINT(1) it might take up less space, but I recently learned that INT(11) just controls display of the field (not space requirements) and wondered if TINYINT was the same. But this clears it up.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.