Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

What are the advantages of MySQL database

2025-02-25 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

This article shows you what the advantages of MySQL database are, the content is concise and easy to understand, it can definitely brighten your eyes. I hope you can get something through the detailed introduction of this article.

What are the advantages of MySQL database

1. License fee

The popularity of MySQL is largely due to its laxity, except for slightly unusual license fees. The price of MySQL varies with platform and installation. The Windows version of MySQL (NT and 9X) is not free under any circumstances, while MySQL of any Unix variant (including Linux) is free if installed by the user or by the system administrator rather than by a third party, and the third solution must pay a license fee.

2. Price

Price of platform installation method

WindowsNT,9X any two hundred dollars

Free self-installation of Unix or Linux

$200USD for Unix or Linux third-party installation

Need an application component for $200

You can get a variety of support contracts, too many contents are no longer listed, the latest quotation can consult the MySQL site.

3. Installation

Most of the major package formats (RPM, DBE, TGZ) are available on the MySQL site, and client libraries and various language "wrappers" (Wrapper) are available in separate RPM formats. Installation in RPM format is not too troublesome and does not require initial configuration. An initial script is generated in rc3.d (for example, RedHatRPM), so the MySQL daemon is started and run when it is restarted in multi-user mode. MySQL's daemon process (mysqld) consumes very little memory (on Pentium 133 running RedHat5.1, each daemon uses 500K memory and another 4m shared memory overhead) and is loaded on the processor only when real queries are executed, which means that MySQL can be used fairly easily for small databases without having too much impact on other system functions.

4. Data type

It is a good thing that fields support a large number of data types. Typical integers, floating-point numbers, strings, and numbers are represented in multiple lengths and support variable-length BLOB (BinaryLargeOBject) types. The date-time field can also be well represented by the automatic increment option for integer fields.

MySQL differs from most other database systems in that it provides two relatively less common field types: ENUM and SET. ENUM is an enumerated type, which is very suitable for the Pascal language. It allows programmers to see field values like 'red,' green', 'blue', while MySQL stores these values as only one byte. SET is also borrowed from Pascal, which is also an enumerated type, but the ability to store multiple enumerated values in a single field may not impress you (and may threaten the definition of the third paradigm), but the correct use of SET and CONTAINS keywords can save a lot of table joins and achieve good performance improvements.

5. SQL compatibility

MySQL contains some changes that are different from the SQL standard, most of which are designed to compensate for the shortcomings of the SQL scripting language. However, other extensions do make MySQL unique; for example, LINK clause search automatically ignores case. MySQL also allows user-defined SQL functions, in other words, a programmer can write a function and integrate it into MySQL, and it behaves no different from any basic function such as SUM () or AVG (). Functions must be compiled into a shared library file (.so file) and then loaded with a LOADFUNCTION command.

It also lacks some common SQL functions and no sub-selections (queries in queries). The View is also gone. Of course, most subqueries can be rewritten with simple join clauses, but sometimes it's easier to think about problems with two nested queries than with one large join. Again, views only hide where clauses for programmers, but this is another convenience that programmers expect.

What are the advantages of MySQL database

6. Stored procedures and triggers

MySQL does not have a stored procedure (StoredProcedure) language, which is the biggest limitation for programmers accustomed to enterprise databases. Multi-statement SQL commands must be coordinated by client code, which is with the help of a fairly sound query language and the ability to lock and unlock tables to allow multiple statements to run.

7. Referential integrity (ReferentialIntegrity-RI)

One of the main drawbacks of MySQL is the lack of a standard RI mechanism; however, the creators of MySQL do not turn a deaf ear to the wishes of their users and provide some solutions. One of them is to support unique indexes. The lack of Rule restrictions (a fixed scope limit on pinned fields) is compensated by a large number of data types. It doesn't simply provide check constraints (limits on the value of one field relative to another field on the same row), external keywords, and the "cascading delete" feature that is often associated with RI. Interestingly, the SQL parser tolerates the syntax of these statements when these features are not supported. The goal is to make it easy to migrate the database to MySQL. This is a good attempt, and it does leave a convenient way to support this feature in the future; however, those who do not read the documentation carefully may mistakenly think that these features actually exist.

7. Security

My biggest complaint about MySQL from beginning to end is its security system, whose only drawback is complexity rather than standard, and only changes when mysqladmin is called to reread user permissions. The usual SQLGRANT/REVOKE statements are not supported until the current version, but at least they have them now. The writers of MySQL extensively document its specific security system, but it does require a learning process that may have no other way.

8. Backup and recovery, data import / export

The lack of mandatory reference consistency significantly simplifies backup and recovery, which can be perfectly replicated by data import / export alone. The LOADDATAINFILE command gives data import a lot of flexibility. The SELECTINTO command implements the equality function of data export. In addition, since MySQL does not use the original partition, all database data can be saved with a file system backup. Database activity can be recorded. Unlike normal database logs (storing records of changes or before / after recording images), MySQL records the actual SQL statements. This allows the database to be restored to the point before the failure, but does not allow commit and rollback operations.

9. Connectivity

MySQL client library is a C language library of client / server structure, which means that a customer can query a database that resides on another machine. However, MySQL's real strength lies in the language "wrapper" in the library, and Perl, Pathon, and PHP are only part of it. Apache's Web server also has many modules, such as directory access files, which allow a variety of Apache configuration information (such as directory access files) to use MySQL. The application program interface is simple, consistent and complete. In addition, multi-platform ODBC drivers are freely available.

10. The future

The development of MySQL continues at a rapid pace. In fact, the pace of development is a challenge for most open source code. Many of the complaints mentioned in this article are being addressed, however, I will not comment on features that do not yet exist. The developers have made it clear to me that adding query capabilities and improving query speed is the highest priority in future development.

11. Summary

Mysql is the centrist in the database field. It lacks most of the main features of a fully functional database, but it has more features than a similar Xbase record storage engine. It needs an active server daemon like an enterprise RDBMS, but it can't consume resources like they do. The query language allows complex join queries, but the integrity of all references must be enforced by the programmer.

MySQL finds a place in the Linux world-providing simplicity and speed, while still providing enough functionality to make programmers happy. Database programmers will like its query capabilities and extensive customer libraries, and database administrators will feel that the system lacks major database functions, and they will find it valuable for simple databases (when there is no guarantee to buy big-name databases).

What are the advantages of MySQL database? have you learned any knowledge or skills? If you want to learn more skills or enrich your knowledge reserve, you are welcome to follow the industry information channel.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report