MySQL & mSQL
Authors: Randy Jay Yarger, George Reese, and Tim King
Publisher: O'Reilly & Associates
Price: $34.95 US
Reviewer: Reuven M. Lerner
Relational databases are based on technology originally invented in the 1970s. Their technology might be old, but databases play a crucial role in our increasingly information-laden world. They are designed to store and retrieve information easily, quickly and reliably.
With the growth of the World Wide Web, many more people have begun to realize how useful a relational database can be. Personalized web pages, shopping carts, calendar/diary sites, stock portfolios and book recommendations are all possible because of the marriage between databases and the Web.
While creating and publishing a web site is relatively inexpensive, databases are normally expensive to buy, require costly hardware, and occupy one or more full-time database administrators. No wonder companies can charge outrageous sums of money for a database—anyone who can afford to install and maintain one can also afford the five-digit purchase price.
The tide is beginning to turn, however, and MySQL & mSQL are two at the forefront of a movement to popularize database use. They can be installed within minutes, require low maintenance, and have outstanding performance. Moreover, they support most of the standard SQL (Structured Query Language) syntax used on larger databases. This means anyone trained on a larger database system will be able to apply that knowledge with MySQL & mSQL. The reverse is also true; MySQL & mSQL allow someone to learn the basics of a relational database before working with Oracle, Sybase, DB2 and other large-scale products.
MySQL & mSQL, new from O'Reilly and Associates, is a good book for someone looking to use one or both of these products. It has an excellent introduction to the theory behind relational databases and explains data normalization—a crucial aspect of good database design—in a relatively clear and concise way. It describes SQL data types, giving frequent examples of how they could be used. I normally use MySQL, and thus, the mSQL portions of the book were irrelevant to my day-to-day work. Nevertheless, I found it useful to see how the two differ and what I might gain or lose by switching. Someone inexperienced with database programming would find it hard to decide between the two, based on the coverage given in this book.
MySQL and mSQL begins by describing databases in general, and then concentrates on these two database products in particular. The book continues with a look at database programming from a number of perspectives, including a wide variety of languages (C, C++, Java, Perl, Python and PHP). Finally, it provides a reference to SQL and several language-specific APIs.
That said, several things about MySQL & mSQL troubled me. I was surprised that the example CGI programs did not use the -T (taint) flag, which can significantly increase a program's security. I would also have preferred to see a longer description of Perl's DBI (database interface), instead of using space for a description of the old Mysql.pm module.
I am starting to learn Python and was happy to see that MySQL & mSQL included a chapter on the subject. Unfortunately, the book did not tell me where a MySQL module for Python could be found or which module was used in the examples. After an hour of searches, downloads and failed installs, I gave up. The authors could certainly have given clearer instructions on this subject.
I was surprised that the DESCRIBE command, which I use extensively in my work, had only one mention in the index—and that pointed to an empty entry in the book's SQL reference.
Beginning users probably need a short, step-by-step demonstration of how to CREATE a table, INSERT a row into it, UPDATE one of its columns, DELETE the row, and finally, DROP the table. MySQL & mSQL describes such commands in great detail, but gives few examples of interactive database commands.
Perhaps my biggest problem with MySQL & mSQL is its lack of attention to potential problems when using these low-end databases. I have been using MySQL for several years, and will continue to use it for many applications, both for myself and my clients. But it lacks useful items such as triggers, stored procedures and nested SELECT statements. More importantly, it lacks transactions and constraints, which help to ensure data safety.
Relational databases typically require much horsepower and maintenance, and the authors would have been wise to give a longer indication of why this is the case. In particular, it would have been nice to read more about transactions, and under what circumstances the added expense of Oracle or Sybase pales in comparison with corporate liability.
Despite its flaws, MySQL & mSQL is a welcome book. It provides far better documentation than has previously been available for these products, and gives a push in the right direction to programmers who are new to relational databases. If you are interested in writing applications that use a database, MySQL & mSQL is a good place to start.
Fast/Flexible Linux OS Recovery
On Demand Now
In this live one-hour webinar, learn how to enhance your existing backup strategies for complete disaster recovery preparedness using Storix System Backup Administrator (SBAdmin), a highly flexible full-system recovery solution for UNIX and Linux systems.
Join Linux Journal's Shawn Powers and David Huffman, President/CEO, Storix, Inc.
Free to Linux Journal readers.Register Now!
- Server Hardening
- The Death of RoboVM
- EnterpriseDB's EDB Postgres Advanced Server and EDB Postgres Enterprise Manager
- BitTorrent Inc.'s Sync
- The Humble Hacker?
- The US Government and Open-Source Software
- Open-Source Project Secretly Funded by CIA
- ACI Worldwide's UP Retail Payments
- New Container Image Standard Promises More Portable Apps
- AdaCore's SPARK Pro
In modern computer systems, privacy and security are mandatory. However, connections from the outside over public networks automatically imply risks. One easily available solution to avoid eavesdroppers’ attempts is SSH. But, its wide adoption during the past 21 years has made it a target for attackers, so hardening your system properly is a must.
Additionally, in highly regulated markets, you must comply with specific operational requirements, proving that you conform to standards and even that you have included new mandatory authentication methods, such as two-factor authentication. In this ebook, I discuss SSH and how to configure and manage it to guarantee that your network is safe, your data is secure and that you comply with relevant regulations.Get the Guide