• Mysql统计总结


    -- 最近30天的医说发布数量
    SELECT substr(a.feed_publish_time,6, 5) AS '日期', count(*) AS '医说数' FROM xm_feed a WHERE
    DATE_SUB(CURDATE(),INTERVAL 30 DAY) <= a.feed_publish_time GROUP BY substr(a.feed_publish_time,1, 10);

    -- 最近30天的医说评论发布数量
    SELECT substr(a.comm_create_time,6, 5) AS '日期', count(*) AS '医说评论数' FROM xm_feed_comment a WHERE DATE_SUB(CURDATE(),INTERVAL 30 DAY) <= a.comm_create_time GROUP BY substr(a.comm_create_time,1, 10);

    -- 最近30天的医说扩散发布数量
    SELECT substr(a.repost_create_time,6, 5) AS '日期', count(*) AS '医说评论数' FROM xm_feed_repost a WHERE DATE_SUB(CURDATE(),INTERVAL 30 DAY) <= a.repost_create_time GROUP BY substr(a.repost_create_time,1, 10);

    -- 最近30天的医说点赞发布数量
    SELECT substr(a.digg_create_time,6, 5) AS '日期', count(*) AS '医说评论数' FROM xm_feed_digg a WHERE DATE_SUB(CURDATE(),INTERVAL 30 DAY) <= a.digg_create_time GROUP BY substr(a.digg_create_time,1, 10);

    -- 昨天的数据
    SELECT count(*) as num FROM xm_user a WHERE a.user_audit_status = 'AUDITED' AND date_sub(current_date(),interval 1 day) = substr(a.user_create_time,1, 10);
    SELECT count(*) as num FROM xm_user a WHERE date_sub(current_date(),interval 1 day) = substr(a.user_create_time,1, 10);
    SELECT count(*) as num FROM xm_feed a WHERE date_sub(current_date(),interval 1 day) = substr(a.feed_publish_time,1, 10);
    SELECT count(*) as num FROM xm_feed_comment a WHERE date_sub(current_date(),interval 1 day) = substr(a.comm_create_time,1, 10);
    SELECT count(*) as num FROM xm_feed_repost a WHERE date_sub(current_date(),interval 1 day) = substr(a.repost_create_time,1, 10);
    SELECT count(*) as num FROM xm_feed_digg a WHERE date_sub(current_date(),interval 1 day) = substr(a.digg_create_time,1, 10);

  • 相关阅读:
    Feature Extractor[ResNet]
    Feature Extractor[inception v2 v3]
    Feature Extractor[batch normalization]
    Feature Extractor[googlenet v1]
    Feature Extractor[content]
    Feature Extractor[VGG]
    object detection[rfcn]
    【小白的CFD之旅】05 补充基础
    【小白的CFD之旅】04 任务
    【小白的CFD之旅】03 老蓝
  • 原文地址:https://www.cnblogs.com/kenshinobiy/p/4920723.html
Copyright © 2020-2023  润新知