logo
publist
写文章

简介

该用户还未填写简介

擅长的技术栈

可提供的服务

暂无可提供的服务

select count(0)或者select count(*)等非常慢的优化(一)

一、故事背景项目组联系我说是有一张 500w 左右的表做select count(*)速度特别慢。二、原 SQL 分析Server version: 5.7.24-log MySQL Community Server (GPL)SQL 如下,仅仅就是统计api_runtime_log这张表的行数,一条简单的不能再简单的 SQL:select count(*) from api_runtime_lo

#sql#mysql#linq
到底了