: This article mainly introduces a Mysql table creation statement. if you are interested in the PHP Tutorial, refer to it.
1 drop table if exists 'nuvue '; 2 3 create table 'nuvue' (4 'id' INT (10) unsigned not null AUTO_INCREMENT, 5 'status' TINYINT (2) unsigned not null default 0 COMMENT 'status', 6 'uid' INT (10) unsigned not null comment 'create user', 7' province _ id' TINYINT (3) unsigned not null comment 'level 1 City', 8'city _ id' TINYINT (3) unsigned not null comment 'level 2 region', 9'name' VARCHAR (100) not null comment 'site name', 10' logo _ url' VARCHAR (100) not null comment 'site Logo ', 11' location _ address' VARCHAR (200) not null comment 'site address', 12 'location _ point' VARCHAR (30) not null comment 'site coordinate ', 13 'caoncat _ phone' VARCHAR (20) not null comment 'contact phone', 14 'type' ENUM ('livehouse', 'theare', 'bar', 'bookshop', 'other ') not null comment 'site type', 15 'phone' VARCHAR (20) not null comment 'site phone', 16 'region' VARCHAR (10) not null comment 'site region ', 17 'people' VARCHAR (10) not null comment 'number of registration', 18 'device' VARCHAR (100) not null default '''comment' site device ', 19 'insert' VARCHAR (100) not null default ''' COMMENT 'site introduction', 20' create _ at 'datetime not null comment' creation time ', 21 primary key 'id' ('id'), 22 unique key 'name' ('name'), 23 KEY 'idx _ type' ('type '), 24 KEY 'idx _ uid' ('uid'), 25 KEY 'idx _ status' ('status'), 26 KEY 'idx _ location' ('Province _ id ', 'City _ id') 27) ENGINE = Myisam default charset = utf8;
The above introduces a Mysql table creation statement, including some content. I hope my friends who are interested in the PHP Tutorial can help me.