2016年12月17日
摘要: By francis_haoDec 17,2016 统计函数数据记录查询 统计函数 统计函数描述count()count(*):统计表中记录条数(包括NULL值字段) count(field): 统计表中记录条数(不包括NULL值字段)avg()计算字段值的平均值sum()计算字段值总和max()查询字段值最大值min()查询字段值最小值mysql> select function(fie... 阅读全文
posted @ 2016-12-17 22:26 刘英皓 阅读(4116) 评论(0) 推荐(0) 编辑
摘要: By francis_haoDec 17,2016 排序数据记录查询 排序是指将筛选出符合条件的数据进行有序排放,有升序(ASC(默认))方式和降序(DESC)方式。 mysql> select field1,field2…… from table_name [where 条件] order by fieldm1 [asc|desc],fieldm2 asc|desc,……; 这里... 阅读全文
posted @ 2016-12-17 20:47 刘英皓 阅读(349) 评论(0) 推荐(0) 编辑
摘要: By francis_haoDec 17,2016 条件数据记录查询 mysql> select field1,field2…… from table_name where 条件; 其中条件的形式有以下几种 条件为关系运算符和逻辑运算符 MySQL支持的比较运算符 运算符描述>大于=大于等于 select field1,field2…… from table_name where f... 阅读全文
posted @ 2016-12-17 18:12 刘英皓 阅读(321) 评论(0) 推荐(0) 编辑