--创建数据样例表

CREATE TABLE `day_weight_tb` (

`day_date` varchar(16) DEFAULT NULL,

`in_weight` varchar(64) DEFAULT NULL,

`out_weight` varchar(64) DEFAULT NULL

) ENGINE=InnoDB DEFAULT CHARSET=utf8;--插入样例数据

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2018-03-10‘, ‘18.84‘, ‘74.14‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-01-21‘, ‘17.69‘, ‘25.97‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-02-01‘, ‘16.48‘, ‘10.0‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-01-29‘, ‘10.9‘, ‘74.12‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-02-13‘, ‘15.25‘, ‘16.62‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-01-12‘, ‘19.21‘, ‘95.42‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-02-14‘, ‘26.38‘, ‘20.59‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-01-24‘, ‘15.99‘, ‘16.823‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-01-13‘, ‘94.846‘, ‘56.256‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-03-03‘, ‘15.63‘, ‘12.128‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-03-12‘, ‘14.282‘, ‘24.046‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-01-16‘, ‘14.045‘, ‘11.73‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-03-08‘, ‘23.41‘, ‘23.441‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-01-31‘, ‘11.177‘, ‘4332.26‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-01-23‘, ‘11.8‘, ‘17104.49‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-03-17‘, ‘17.95‘, ‘13.81‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-03-01‘, ‘19.23‘, ‘20.43‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-02-05‘, ‘21.55‘, ‘51.0‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-02-27‘, ‘13.003‘, ‘23.32‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-03-11‘, ‘16.44‘, ‘24.44‘);

INSERT INTO `day_weight_tb` (`day_date`, `in_weight`, `out_weight`) VALUES (‘2019-02-28‘, ‘16.48‘, ‘23.4‘);

mysql按周统计_MySQL按周统计 WEEK 实例相关推荐

  1. mysql数据入库时间的统计_MySQL按时间统计数据的方法总结

    在做数据库的统计时,经常会需要根据年.月.日来统计数据,然后配合echarts来制作可视化效果. 数据库:MySQL 思路 按照时间维度进行统计的前提是需要数据库中有保留时间信息,建议是使用MySQL ...

  2. mysql日期格式化季度_Mysql按周,按月,按日,按小时分组统计数据

    按周 select DATE_FORMAT(create_time,'%Y%u') weeks,count(caseid) count from tc_case group by weeks; 按月 ...

  3. mysql week统计_MySQL按周统计 WEEK 实例

    --创建数据样例表 CREATE TABLE `day_weight_tb` ( `day_date` varchar(16) DEFAULT NULL, `in_weight` varchar(64 ...

  4. mysql 时间戳 三天_MySQL格式化时间戳 统计当日,第二天,第三天,3个工作日以后的数据...

    mysql 查询出来的处理时间和开始时间都是13位的时间戳 SELECT `END_TIME`,`CREATE_TIME` FROM t_table 需求是统计当日,第二天,第三天,3个工作日以后的时 ...

  5. mysql 分时统计_mysql中数据统计的技巧备忘录

    mysql 作为常用数据库,操作贼六是必须的,对于数字操作相关的东西,那是相当方便,本节就来拎几个统计案例出来供参考! order订单表,样例如下: CREATE TABLE `yyd_order` ...

  6. mysql求和 子查询_MYSQL 查询方法 统计查询 链接查询 子查询

    mysql表格查询方法: 查询: 1.简单查询 select * from Info --查所有数据 select Code,Name from Info --查指定列的数据 select Code ...

  7. mysql周报内容范文_Mysql各种表格查询含实例,日报,周报,月报,时间差自动计算...

    publicList<IReport>retrieve(IReportreport){List<IReport>list=newArrayList<IReport> ...

  8. mysql周报内容范文_Mysql各种报表查询含实例,日报,周报,月报,时间差自动计算...

    public List retrieve(IReport report) { List list = new ArrayList(); Map map = new HashMap(); // 设置结束 ...

  9. mysql 创建删除表_mysql创建删除表的实例详解

    表的创建命令需要: 表的名称 字段名称 定义每个字段(类型.长度等) 语法 下面是通用的SQL语法用来创建MySQL表: CREATE TABLE table_name (column_name ...

最新文章

  1. NB-IOT: Anchor Carrier 锚点载波
  2. PHP支持模板,让ThinkPHP5支持模板主题(参照ThinkPHP3.2)
  3. 不同表_不同电脑剪视频的速度对比表20200617更新;附素材和方法
  4. Oracle增加修改删除字段/主键
  5. Could not find qmake configuration file解决
  6. Springboot整合Quartz集群部署以及配置Druid数据源
  7. 怎么将翼型导入catia_CATIA导入翼型出现了问题,翼型是在网上找的。说是样条线运算有问题 - 机械 - 小木虫 - 学术 科研 互动社区...
  8. c语言如何打印unicode字符,如何在C ++中打印Unicode字符?
  9. android中FileObserver的运用
  10. Java课程设计---Eclipse基本环境配置
  11. 计算机毕业设计java+ssm校园在线投票系统(源码+系统+mysql数据库+Lw文档)
  12. mysql批量抽取数据_批量从数据库是提取数据,并显示出来。
  13. mysql周德伟课后答案_MySQL数据库技术-周德伟
  14. atom平台 android ia,ZTE Grand X IN:搭载Atom平台的Android机
  15. 美团放弃公有云业务、苏宁云商城停止服务
  16. CH343芯片应用—硬件设计指南
  17. 通过集成腾讯 IM 来浅尝一下.net 6 的 MINI API
  18. 万亿金融大数据市场待开发
  19. 计算IP地址的有效范围
  20. [洛谷P1856] [USACO5.5]矩形周长Picture

热门文章

  1. 一则关于运算符的小例
  2. JS中使用EL表达式
  3. Python 之vim编写python自动补全
  4. 用自定义代码分析来标准开发人员的开发规范
  5. Java™ 教程(Collection接口)
  6. 2016年研究数据可视化最不应该错过的10篇文章
  7. 【Python实战】Django建站笔记
  8. Java反射机制简单使用
  9. 大道至简,回归到梦开始的地方。人生如此,编程亦如此。
  10. Ecshop与Jquery冲突的完美解决方案(实践过,有效)