mysql> create database yoohouse_image default character set=utf8;
Query OK, 1 row affected (0.03 sec)
mysql> use yoohouse_image;
Database changed
mysql> CREATE TABLE `image_blacklist` (
-> `image_hash` char(32) NOT NULL,
-> `create_time` int(10) unsigned DEFAULT NULL,
-> PRIMARY KEY (`image_hash`),
-> KEY `create_time` (`create_time`)
-> ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
Query OK, 0 rows affected (0.04 sec)
mysql> CREATE TABLE `image_hash` (
-> `image_id` bigint(20) unsigned NOT NULL AUTO_INCREMENT,
-> `image_hash` char(32) DEFAULT NULL,
-> `image_host` tinyint(2) DEFAULT NULL,
-> `image_extension` char(5) DEFAULT NULL,
-> `create_time` int(10) unsigned DEFAULT NULL,
-> PRIMARY KEY (`image_id`),
-> KEY `image_hash` (`image_hash`),
-> KEY `create_time` (`create_time`),
-> KEY `image_host` (`image_host`)
-> ) ENGINE=MyISAM DEFAULT CHARSET=utf8;
Query OK, 0 rows affected (0.06 sec)
mysql> show tables;
+--------------------------+
| Tables_in_yoohouse_image |
+--------------------------+
| image_blacklist |
| image_hash |
+--------------------------+
2 rows in set (0.00 sec)
阅读(574) | 评论(0) | 转发(0) |