Jump to ratings and reviews
Rate this book

MySQL Cookbook: Solutions for Database Developers and Administrators

Rate this book

MySQL’s popularity has brought a flood of questions about how to solve specific problems, and that’s where this cookbook is essential. When you need quick solutions or techniques, this handy resource provides scores of short, focused pieces of code, hundreds of worked-out examples, and clear, concise explanations for programmers who don’t have the time (or expertise) to solve MySQL problems from scratch.

Ideal for beginners and professional database and web developers, this updated third edition covers powerful features in MySQL 5.6 (and some in 5.7). The book focuses on programming APIs in Python, PHP, Java, Perl, and Ruby. With more than 200+ recipes, you’ll learn how to:

Use the mysql client and write MySQL-based programs Create, populate, and select data from tables Store, retrieve, and manipulate strings Work with dates and times Sort query results and generate summaries Use stored routines, triggers, and scheduled events Import, export, validate, and reformat data Perform transactions and work with statistics Process web input, and generate web content from query results Use MySQL-based web session management Provide security and server administration

1281 pages, Kindle Edition

First published November 1, 2002

38 people are currently reading
254 people want to read

About the author

Paul DuBois

55 books6 followers
Paul DuBois is the author of MySQL (Addison-Wesley Professional); MySQL Cookbook, Using csh & tcsh, and Software Portability with imake (O'Reilly); and MySQL and Perl for the Web (New Riders).

Ratings & Reviews

What do you think?
Rate this book

Friends & Following

Create a free account to discover what your friends think of this book!

Community Reviews

5 stars
61 (33%)
4 stars
66 (36%)
3 stars
47 (25%)
2 stars
7 (3%)
1 star
2 (1%)
Displaying 1 - 10 of 10 reviews
Profile Image for Matt.
Author 50 books21 followers
October 24, 2007
I rarely read programming books, and even more infrequently have anything nice to say about them. But I found this book to be a great list of recipes, suggestions, and insider's tips for writing good SQL (Standard Query Language -- the language you use to talk to relational databases).

Paul Dubois is a notable expert in the field anyway. If I recall correctly, he's the documentation lead for the MySQL project. Thus, he's certainly well qualified to write something like this.

The tips (or most of them, at least) are highly readable, often practical, and are accompanied with illuminating text (not to be confused with ILLUMINATED text, which would certainly be a first in the programming world).

One thing was noticeably absent, though: tips on tuning queries. Dear Paul Dubois: If you ever read this, please add a section on tuning queries, using EXPLAIN, and improving overall DB performance.
Profile Image for Chris Patterson.
7 reviews1 follower
August 16, 2018
This is my goto book for SQL scripts. If there is an issue I'm having with something deep I can merge the concepts and scripts in this book to get the result I'm looking for.
Profile Image for Michael Milawski.
12 reviews1 follower
June 23, 2022
A good book for mysql. It contains not only many sql queries but also solutions for problems that are not really solvable by sql queries alone, it shows code examples for that matter. It also shows ways of how to configure the server correctly. Very useful book.
12 reviews
April 19, 2010
This is a good reference book containing pre-canned routines for accessing and manipulating a MySQL database. It is a good starting point for making routines to generate reports or validate data.

One other book on my list: MySQL Stored Procedure Programming is a good companion read to this one, as it shows the particulars of how to write logic on the server side. The code in the Cookbook can be used on the server side with ease. The other book also has more advice on how to optimize MySQL code when it does not have satisfactory performance.
Profile Image for Adrian.
12 reviews908 followers
January 29, 2007
A little bland... ba-dump-bump-bing. It had some interesting ideas for monitoring server status programatically, views for summary tables, and gathering stats/logs with triggers. When I do more of those things in detail, I may glance at certain parts again. Available online at Safari Books. [Skimmed w/some reading]
Profile Image for Vaughn.
12 reviews
September 2, 2008
Ha ha, just kidding. But seriously, I am reading this, slowly, for cause, which is the only reason why anyone would...

Update: It did the trick. Quick access to many little tricks that would have taken too much time to think up myself. Sweet. Recommended!
Profile Image for Yuan.
49 reviews
October 4, 2021
Love the structure! It provides you options to go through all the MySql “recipes” quickly and dive into details!
Used the book for repairing technical test interview. Will go through the details to enhance understanding for sure.
Displaying 1 - 10 of 10 reviews

Can't find what you're looking for?

Get help and learn more about the design.