Home Database Mysql Tutorial MySQL两项性能的基本测试浅谈

MySQL两项性能的基本测试浅谈

Jun 07, 2016 pm 04:11 PM
mysql Basic performance us test

我们今天是要和大家一起讨论的是MySQL两项性能的基本测试,我前两天在一信誉度很好的网站看见MySQL两项性能的基本测试的资料,觉得挺好,就拿出来供大家分享。希望你在浏览之后会对其有更深的印象。 以下的文章主要描述的是MySQL两项性能的基本测试,我们使

我们今天是要和大家一起讨论的是MySQL两项性能的基本测试,我前两天在一信誉度很好的网站看见MySQL两项性能的基本测试的资料,觉得挺好,就拿出来供大家分享。希望你在浏览之后会对其有更深的印象。

以下的文章主要描述的是 MySQL两项性能的基本测试,我们使用的是 212992条数据在同一台机器上来执行update的实际操作,采用的是 MySQL5.0版。主要目的是对两项性能进行测试,以下就是详细内容。

MySQL两项性能测试之一使用存储过程性能可以提升多少?

MySQL的存储过程从无到有,已经是很大的进步了,但网上有些人说,MySQL的存储过程性能没什么提升,甚至还不如不用存储过程比较快,耳听为虚,眼见为实,所以我就自己亲自做了一个测试,结果如下:

使用存储过程 没有使用存储过程

1. 10985ms 14906ms

2. 11562ms 14828ms

3. 11890ms 14500ms

4. 11360ms 15047ms

5. 12407ms 14578ms

结论:我个人认为存储过程在数据量大的情况下,肯定性能上有更大的优势的,所以说MySQL存储过程没有什么效率的人明显是误人子弟!东西可以乱吃,话可不能乱说

MySQL两项性能测试之二分页测试

MySQL有了limit,使分页变得简单多了,但是听说limit还是存在性能问题,所以需要优化,这是根据我上一篇文字的优化方法,对其进行测试,看看这种是否有效

直接limit 10,10 先做offset 10,在选出10

1. 10ms 15ms

2. 10ms 15ms

3. 10ms 15ms

直接limit 100000,10 先做offset 100000,在选出10

1. 78ms 46ms

2. 78ms 47ms

3. 78ms 47ms

直接limit 200000,10 先做offset 200000,在选出10

1. 156ms 79ms

2. 188ms 78ms

3. 153ms 78ms

4. 141ms 94ms

5. 141ms 93ms

直接limit 200000,10000 先做offset 200000,在选出10000

1. 171ms 94ms

2. 140ms 78ms

3. 172ms 93ms

4. 156ms 93ms

5. 157ms 94ms

以上的相关内容就是对MySQL两项性能测试的介绍,望你能有所收获。 


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

Hot AI Tools

Undresser.AI Undress

Undresser.AI Undress

AI-powered app for creating realistic nude photos

AI Clothes Remover

AI Clothes Remover

Online AI tool for removing clothes from photos.

Undress AI Tool

Undress AI Tool

Undress images for free

Clothoff.io

Clothoff.io

AI clothes remover

AI Hentai Generator

AI Hentai Generator

Generate AI Hentai for free.

Hot Article

R.E.P.O. Energy Crystals Explained and What They Do (Yellow Crystal)
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. Best Graphic Settings
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌
R.E.P.O. How to Fix Audio if You Can't Hear Anyone
3 weeks ago By 尊渡假赌尊渡假赌尊渡假赌

Hot Tools

Notepad++7.3.1

Notepad++7.3.1

Easy-to-use and free code editor

SublimeText3 Chinese version

SublimeText3 Chinese version

Chinese version, very easy to use

Zend Studio 13.0.1

Zend Studio 13.0.1

Powerful PHP integrated development environment

Dreamweaver CS6

Dreamweaver CS6

Visual web development tools

SublimeText3 Mac version

SublimeText3 Mac version

God-level code editing software (SublimeText3)

The page is blank after PHP is connected to MySQL. What is the reason for the invalid die() function? The page is blank after PHP is connected to MySQL. What is the reason for the invalid die() function? Apr 01, 2025 pm 03:03 PM

The page is blank after PHP connects to MySQL, and the reason why die() function fails. When learning the connection between PHP and MySQL database, you often encounter some confusing things...

How to efficiently integrate Node.js or Python services under LAMP architecture? How to efficiently integrate Node.js or Python services under LAMP architecture? Apr 01, 2025 pm 02:48 PM

Many website developers face the problem of integrating Node.js or Python services under the LAMP architecture: the existing LAMP (Linux Apache MySQL PHP) architecture website needs...

How to share the same page on the PC and mobile side and handle cache issues? How to share the same page on the PC and mobile side and handle cache issues? Apr 01, 2025 pm 01:57 PM

How to share the same page on the PC and mobile side and handle cache issues? In the nginx php mysql environment built using the Baota background, how to make the PC side and...

Is Debian Strings compatible with multiple browsers Is Debian Strings compatible with multiple browsers Apr 02, 2025 am 08:30 AM

"DebianStrings" is not a standard term, and its specific meaning is still unclear. This article cannot directly comment on its browser compatibility. However, if "DebianStrings" refers to a web application running on a Debian system, its browser compatibility depends on the technical architecture of the application itself. Most modern web applications are committed to cross-browser compatibility. This relies on following web standards and using well-compatible front-end technologies (such as HTML, CSS, JavaScript) and back-end technologies (such as PHP, Python, Node.js, etc.). To ensure that the application is compatible with multiple browsers, developers often need to conduct cross-browser testing and use responsiveness

Docker builds LNMP environment: Is a single Dockerfile or Docker Compose better? Docker builds LNMP environment: Is a single Dockerfile or Docker Compose better? Apr 01, 2025 pm 02:09 PM

Dockerfile Best Practice for Building LNMP Environment Learning During Docker, many developers try to build their own LNMP (Linux, Nginx, MySQL, PHP)...

Comparison of Redis queues and MySQL stability: Why is Redis prone to data loss? Comparison of Redis queues and MySQL stability: Why is Redis prone to data loss? Apr 01, 2025 pm 02:24 PM

Comparison of Redis queues and MySQL stability: Why is Redis prone to data loss? In the development environment, using PHP7.2 and ThinkPHP frameworks, we often face the choice of cooperation...

When using Django and MySQL to process hundreds of thousands to one or two million pieces of data, what kind of cache solution should a 4-core 8G memory server choose? When using Django and MySQL to process hundreds of thousands to one or two million pieces of data, what kind of cache solution should a 4-core 8G memory server choose? Apr 01, 2025 pm 11:36 PM

Using Django and MySQL to process large data volumes When using Django and MySQL databases, if your data volume reaches hundreds of thousands to one or two million...

See all articles