-
分类描述依赖于分类,分类又依赖于商品名称,而商品名称为主键——关键字段查看全部
-
mysql> create table testtime(id int auto_increment not null,timestr int,PRIMARY KEY(id)); Query OK, 0 rows affected (0.01 sec) mysql> desc testtime; +---------+---------+------+-----+---------+----------------+ | Field | Type | Null | Key | Default | Extra | +---------+---------+------+-----+---------+----------------+ | id | int(11) | NO | PRI | NULL | auto_increment | | timestr | int(11) | YES | | NULL | | +---------+---------+------+-----+---------+----------------+ 2 rows in set (0.01 sec) mysql> insert into testtime(timestr) values(UNIX_TIMESTAMP('2014-06-01 21:00:00')); Query OK, 1 row affected (0.00 sec) mysql> select FROM_UNIXTIME(timestr) from testtime; +------------------------+ | FROM_UNIXTIME(timestr) | +------------------------+ | 2014-06-01 21:00:00 | +------------------------+ 1 row in set (0.00 sec)查看全部
-
优化方案: 1.sql 索引 2.数据库结构 3.系统配置 4.硬件查看全部
-
1.数据库timeout 2.满查询 3.组赛查看全部
-
选择合适的数据类型查看全部
-
索引的维护及优化——删除不用的索引 但是有一些索引在主没有使用,但在从还在使用,这样的应该保留,要注意查看全部
-
通过列的唯一值来判断 mysql> select count(distinct customer_id),count(distinct staff_id) from payment; +-----------------------------+--------------------------+ | count(distinct customer_id) | count(distinct staff_id) | +-----------------------------+--------------------------+ | 599 | 2 | +-----------------------------+--------------------------+ 1 row in set (0.01 sec) mysql>查看全部
-
判断哪个列的离散度更高,高的更适合联合索引查看全部
举报
0/150
提交
取消