Tinyint as column type : Tiny Int « Data Type « SQL / MySQL






Tinyint as column type

      
mysql>
mysql> create table SALES_REPRESENTATIVE(
    ->   EMPLOYEE_NO int,
    ->   SURNAME varchar(40),
    ->   FIRST_NAME varchar(30),
    ->   COMMISSION tinyint
    -> );
mysql>
mysql>
mysql> drop table SALES_REPRESENTATIVE;
Query OK, 0 rows affected (0.01 sec)

   
    
    
    
    
    
  








Related examples in the same category

1.Define and use tiny int
2.TINYINT(m) 8-bit integer (1 byte, -128 to +127);
3.Setting M to a higher value than the type allows will not allow you to extend its limit.