MySQL is one of a number of popular website database solutions: other options include PostgreSQL and Firebird. The popularity of MySQL stems in large part from the fact that the database system both free and open source, and has strong community support. Most web hosting providers supply MySQL as the default database system for sites.
MySQL (pronounced either as “My SQL” or “My Sequel”) was developed by Ulf Michael (“Monty”) Widenius and David Axmark. “SQL” stands for Structured Query Language, the language in which its databases and tables are created, modified, and manipulated; the “My” is for Michael’s daughter. While the company originally formed to promote MySQL has undergone several mergers and acquisitions, and while there is a commercial version of MySQL available (used in high-demand sites such as Wikipedia, Facebook, Google, Flickr and Twitter), the open-source version is free, and always will be.
There are many tools for interacting with MySQL data, including the MySQL Workbench for Windows, Mac and Linux, but the most common encountered by web developers is phpMyAdmin, which is built into many web hosting packages and servers.
One of the primary advantages of SQL languages is that simple database queries are written in a very human-readable way. For example:
SELECT * from camels where humps = 2 ORDER BY species
In this case, the query could be translated as “Select everything from the camels
table that has a value of 2 in the humps
field and provide the result in alphabetical order using the species
field.” As a result, Bactrian camels would be listed first (not that there are any other surviving two-humped camel species).
Database-as-language
One aspect of MySQL that can be confusing at first but valuable once grasped is that the language is the database; every action taken with the database is written in MySQL, as is the database itself. (Take a look at some of the printouts of the MySQL activity as you press buttons in phpMyAdmin, for example, or read an exported MySQL database as text).
Enjoy this piece? I invite you to follow me at twitter.com/dudleystorey to learn more.