ENGINE
ENGINE is a SQL statement in the MySQL Specific category. Specifies the MySQL storage engine. InnoDB (default) supports transactions and foreign keys. MyISAM is faster for read-heavy. The syntax is CREATE TABLE ... ENGINE = InnoDB;. It returns table with engine. A typical example: CREATE TABLE fast_cache (id INT, data TEXT) ENGINE=MyISAM; CREATE TABLE orders (id INT, amount DECIMAL(10,2)) ENGINE=InnoDB; -- Check storage engines: SHOW TABLE STATUS WHERE Name = 'orders'; A close relative is AUTO_INCREMENT, which mySQL auto-generates sequential integer values for this column. Commonly used with PRIMARY KEY. A close relative is LAST_INSERT_ID(), which returns the AUTO_INCREMENT value generated by the most recent INSERT in the current connection. A close relative is ON DUPLICATE KEY UPDATE, which mySQL extension: if INSERT causes a duplicate key error, it performs an UPDATE instead. More about this category: MySQL-specific features — AUTO_INCREMENT, ENGINE, SHOW TABLES, LIMIT. Related MySQL Specific entries: AUTO_INCREMENT, LAST_INSERT_ID(), ON DUPLICATE KEY UPDATE, LOAD DATA INFILE, LOCK TABLES / UNLOCK TABLES, FIND_IN_SET(), CHARACTER SET / COLLATION, SELECT ... FOR UPDATE (MySQL).