MySQL Introduction
In this article, we’ll see MySQL Introduction.
Table of Contents
What is MySQL:
MySQL is an open-source Relational Database Management System (RDBMS) that uses Structured Query Language (SQL). SQL is a language programmers use to create, modify and extract data from the relational database and control user access to the database. It is most noted for its quick processing, proven reliability, ease, and flexibility of use.
Its name combines “My”, the name of co-founder Michael Widenius’s daughter, and “SQL”, the abbreviation for Structured Query Language.
A relational database organizes data into one or more data tables in which data types may be related to each other; these relations help structure the data.
A database is a structured collection of data. It may be anything from a simple shopping list to a picture gallery or the vast amounts of information in a corporate network. To add, access, and process data stored in a computer database, you need a database management system such as MySQL Server.
Why Use MySQL
- Open-source and compatible: This simply means that anyone can install and use the basic software, while also enabling third parties to modify and customize the source code. More advanced versions, which offer additional capacity, tools, and services, come with tiered pricing plans. MySQL is also built to be highly compatible with a wide range of systems, programming languages, and technologies, including alternative DBMS solutions. This makes it a simple and practical option for many organizations while reducing fears of being ‘locked in’ to the system.
- Fast and reliable: MySQL was developed for speed, and maintains a reputation for being fast, even if this may come at the expense of some additional features. It is also known for its reliability, backed by a large community of programmers that have put the code through tough testing over the years. Another benefit is that it is relatively simple to learn and use, and seeing as it has been around for nearly three decades, it’s not hard to find experienced MySQL developers when you need them.
- Availability: Online businesses and web platforms need to be able to provide round-the-clock services for a global audience, and high availability is a core feature of MySQL. It uses a range of cluster servers and data replication configurations that ensure uninterrupted uptime even if there is a failure. MySQL also uses a variety of backup and recovery strategies to ensure data is not lost in the event of a system crash or unintentional delete.
- Scalability: As data volumes and user loads increase, the database needs to be scaled up to cope with the additional workload without a drop in performance. MySQL can be scaled in different ways, typically via replication, clustering or sharding (or a combination of them). It is able to support and process very large databases, though this is likely to have an impact on speed.
- Security: This is always an important consideration for businesses as they need to protect sensitive data and defend against cyber attacks. MySQL offers encryption using the Secure Sockets Layer (SSL) protocol, data masking, authentication plugins, and other layers of security to protect data integrity. The Enterprise package also includes firewall protection against cyber attacks.
Advantages and Disadvantages of MySQL:
Advantages:
- It’s Free. Even if you go out and buy enterprise support from Oracle, Percona, or any number of other entities that provide support, you can deploy MySQL on DB servers or cloud instances without worrying about bizarre Oracle licensing schemes. If you’re building a massive data world and don’t want to personally fund Larry’s next yacht, this is a big concern.
- It’s predictable. MySQL is actually a fairly simple database system, so you can be pretty sure that your performance won’t change if the DB size and query mix are approximately the same. This isn’t always true with Oracle.
- It’s actually rather lightweight. MySQL has a single-process, one thread per (active) connection access model. This means that a single MySQL server process can support thousands of simultaneous active database connections, and as long as the machine is well-provisioned, the DB engine is well-configured, and the queries don’t suck, modern MySQL actually scales fairly well.
- It’s extremely well-understood by the world. Just about any problem, you can have with MySQL has happened to 1000 other people, so a quick Google of the problem description will likely yield the right answer (as well as several wrong ones). Oracle is also well-understood, but a lot of the sources tend to be behind paywalls or incomplete answers by consultants who want you to hire them.
Disadvantages:
- It performs quite well for OLTP – especially if you feature your primary keys on joins – but rather badly for analytics queries, as it still only has limited join-method support, particularly in the “main” MySQL forks supported by Oracle and Percona.
- There are several big “gotchas” that trigger table scans, even if they shouldn’t.
- Correlated subqueries are OK, but non-correlated subquery handling is quite poor.
- Stored procedure handling is not awesome.
Hope this article helps you!