Home > Database > Mysql Tutorial > mysql 数据量太大,怎么优化一下

mysql 数据量太大,怎么优化一下

WBOY
Release: 2016-06-06 09:34:38
Original
1145 people have browsed it

mysql

SELECT dir1.url from dir1 LEFT JOIN dir2 on dir2.url=dir1.url where dir2.id is null or dir1.md5dir2.md5
如题,此语句当数据量大的时候会宕机
求助大神帮我想想怎么优化一下

因为我不是做这个的,我只是在c语言一个程序中用到了
然后用我的程序的人说会很慢,而且cpu占用率高
求助帮我优化

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template