MySQL & mSQL

Authors: Randy Jay Yarger, George Reese, and Tim King
Publisher: O'Reilly & Associates
E-mail: info@ora.com
URL: http://www.ora.com/
Price: $34.95 US
ISBN: 1-56592-434-7
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.

Realizing the promise of Apache® Hadoop® requires the effective deployment of compute, memory, storage and networking to achieve optimal results. With its flexibility and multitude of options, it is easy to over or under provision the server infrastructure, resulting in poor performance and high TCO. Join us for an in depth, technical discussion with industry experts from leading Hadoop and server companies who will provide insights into the key considerations for designing and deploying an optimal Hadoop cluster.
Sponsored by AMD
Built-in forensics, incident response, and security with Red Hat Enterprise Linux 6
Every security policy provides guidance and requirements for ensuring adequate protection of information and data, as well as high-level technical and administrative security requirements for a system in a given environment. Traditionally, providing security for a system focuses on the confidentiality of the information on it. However, protecting the data integrity and system and data availability is just as important. For example, when processing United States intelligence information, there are three attributes that require protection: confidentiality, integrity, and availability.
Learn more about catching the bad guy in this free white paper.
Sponsored by DLT Solutions
| Designing Electronics with Linux | May 22, 2013 |
| Dynamic DNS—an Object Lesson in Problem Solving | May 21, 2013 |
| Using Salt Stack and Vagrant for Drupal Development | May 20, 2013 |
| Making Linux and Android Get Along (It's Not as Hard as It Sounds) | May 16, 2013 |
| Drupal Is a Framework: Why Everyone Needs to Understand This | May 15, 2013 |
| Home, My Backup Data Center | May 13, 2013 |
- New Products
- Linux Systems Administrator
- Senior Perl Developer
- Technical Support Rep
- UX Designer
- Web & UI Developer (JavaScript & j Query)
- Designing Electronics with Linux
- Dynamic DNS—an Object Lesson in Problem Solving
- Making Linux and Android Get Along (It's Not as Hard as It Sounds)
- Using Salt Stack and Vagrant for Drupal Development
Enter to Win an Adafruit Pi Cobbler Breakout Kit for Raspberry Pi

It's Raspberry Pi month at Linux Journal. Each week in May, Adafruit will be giving away a Pi-related prize to a lucky, randomly drawn LJ reader. Winners will be announced weekly.
Fill out the fields below to enter to win this week's prize-- a Pi Cobbler Breakout Kit for Raspberry Pi.
Congratulations to our winners so far:
- 5-8-13, Pi Starter Pack: Jack Davis
- 5-15-13, Pi Model B 512MB RAM: Patrick Dunn
- 5-21-13, Prototyping Pi Plate Kit: Philip Kirby
- Next winner announced on 5-27-13!
Featured Jobs
| Linux Systems Administrator | Houston and Austin, Texas | Host Gator |
| Senior Perl Developer | Austin, Texas | Host Gator |
| Technical Support Rep | Houston and Austin, Texas | Host Gator |
| UX Designer | Austin, Texas | Host Gator |
| Web & UI Developer (JavaScript & j Query) | Austin, Texas | Host Gator |
Free Webinar: Hadoop
How to Build an Optimal Hadoop Cluster to Store and Maintain Unlimited Amounts of Data Using Microservers
Realizing the promise of Apache® Hadoop® requires the effective deployment of compute, memory, storage and networking to achieve optimal results. With its flexibility and multitude of options, it is easy to over or under provision the server infrastructure, resulting in poor performance and high TCO. Join us for an in depth, technical discussion with industry experts from leading Hadoop and server companies who will provide insights into the key considerations for designing and deploying an optimal Hadoop cluster.
Some of key questions to be discussed are:
- What is the “typical” Hadoop cluster and what should be installed on the different machine types?
- Why should you consider the typical workload patterns when making your hardware decisions?
- Are all microservers created equal for Hadoop deployments?
- How do I plan for expansion if I require more compute, memory, storage or networking?




8 hours 42 min ago
14 hours 28 min ago
14 hours 45 min ago
16 hours 38 min ago
18 hours 32 min ago
1 day 1 hour ago
1 day 1 hour ago
1 day 3 hours ago
1 day 9 hours ago
1 day 13 hours ago