惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

罗磊的独立博客
Cisco Talos Blog
Cisco Talos Blog
C
Check Point Blog
博客园_首页
Recent Commits to openclaw:main
Recent Commits to openclaw:main
Martin Fowler
Martin Fowler
Recorded Future
Recorded Future
S
Security @ Cisco Blogs
L
LINUX DO - 最新话题
博客园 - 司徒正美
P
Privacy International News Feed
G
Google Developers Blog
I
Intezer
Hacker News - Newest:
Hacker News - Newest: "LLM"
博客园 - 聂微东
The GitHub Blog
The GitHub Blog
C
Cybersecurity and Infrastructure Security Agency CISA
www.infosecurity-magazine.com
www.infosecurity-magazine.com
Scott Helme
Scott Helme
K
Kaspersky official blog
I
InfoQ
Y
Y Combinator Blog
T
The Blog of Author Tim Ferriss
Webroot Blog
Webroot Blog
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
大猫的无限游戏
大猫的无限游戏
D
Docker
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
W
WeLiveSecurity
Microsoft Azure Blog
Microsoft Azure Blog
Spread Privacy
Spread Privacy
量子位
H
Hacker News: Front Page
Simon Willison's Weblog
Simon Willison's Weblog
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
SecWiki News
SecWiki News
S
Security Affairs
Latest news
Latest news
人人都是产品经理
人人都是产品经理
C
CERT Recently Published Vulnerability Notes
S
Security Archives - TechRepublic
V
Visual Studio Blog
T
Troy Hunt's Blog
S
Secure Thoughts
F
Fortinet All Blogs
V
V2EX
The Register - Security
The Register - Security
J
Java Code Geeks
MongoDB | Blog
MongoDB | Blog
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO

博客园 - 天纯蓝

go错误总结(27条) GO语言最主的特性 解决“Comparison method violates its general contract!” Centos7 Mysql5.7主从服务器配置 maven buid 导出项目依赖的jar包问题 [数据库]漫谈ElasticSearch关于ES性能调优几件必须知道的事(转) MongoDB 聚合管道(Aggregation Pipeline) mongodb分布式查询 MongoDB JAVA API Filters mongodb.conf配置文件详解 mongodb安装配置 Elasticsearch-2.3.x填坑之路 CentOS VMware 下SSH配置方法详解 15个nosql数据库 Elasticsearch 相关名词理解 Elasticsearch集群中处理大型日志流的几个常用概念 ES配置文件参考与参数详解 Java连接Elasticsearch集群 Linux下Tomcat的启动、关闭、杀死进程
MySql 优化
天纯蓝 · 2016-04-07 · via 博客园 - 天纯蓝

1、在海量查询时尽量少用格式转换。

2、ORDER BY 和 GROPU BY:使用 ORDER BY 和 GROUP BY 短语,任何一种索引都有助于 SELECT 的性能提高。

3、任何对列的操作都将导致表扫描,它包括数据库教程函数、计算表达式等等,查询时要尽可能将操作移 至等号右边。

4、IN、OR 子句常会使用工作表,使索引失效。如果不产生大量重复值,可以考虑把子句拆开。拆开的子 句中应该包含索引。

5、只要能满足你的需求,应尽可能使用更小的数据类型:例如使用 MEDIUMINT 代替 INT

6、尽量把所有的列设置为 NOT NULL,如果你要保存 NULL,手动去设置它,而不是把它设为默认值。

7、尽量少用 VARCHAR、TEXT、BLOB 类型

8、如果你的数据只有你所知的少量的几个。最好使用 ENUM 类型

9、正如 graymice 所讲的那样,建立索引。

10、合理用运分表与分区表提高数据存放和提取速度。