`
mr.lili
  • 浏览: 149833 次
  • 性别: Icon_minigender_1
  • 来自: 成都
文章分类
社区版块
存档分类

mysql分表记录查询同一用户在不同日志表的相关记录。即多表查询,无关联条件

 
阅读更多
(select count(id) as num from con_logs_2018_01_10 where uid = '12081427281340000' )
union all
(select count(id) as num from con_logs_2018_01_09 where uid = '12081427281340000')

在日志分表后,需要统计 该用户的日志记录信息,需要查询多分表,但无关联关系
分享到:
评论
Global site tag (gtag.js) - Google Analytics