March 04, 2008

Book Review: DB2 9 for Linux, Unix and Windows DBA Guide

When I started reading "DB2 9 for Linux, Unix and Windows DBA Guide, Reference, and Exam Prep" (sixth edition), it seemed like every other DB2 book. But I soon realized there is much more here. Of course there's the standard fare about DB2 history and getting started with installation. Overall though, the authors provide a wealth of knowledge that you just won't find in other books or delivered DB2 documentation.

This book is an excellent resource for anyone working with DB2 9 for Linux, UNIX and Windows (LUW). DBAs will enjoy the chapters on controlling connections to the database. Included here is a list of database objects too long to repeat. You'll learn in great detail about data storage management, maintaining data with runstats and reorganization utilities, database recovery and performance monitoring and tuning of the database as well as the application.

Developers will like the section on SQL, which covers advanced SQL topics including recursive SQL, outer joins, OLAP features, CASE expressions, summary tables, sequences and pureXML. I really appreciate that the authors discuss application development considerations like concurrency and data integrity. They also address application development options such as embedded SQL, ODBC, JDBC, SQLJ and .NET, and examine the development considerations with each of these options.

The end of the book provides an appendix with DB2 9 certification test objectives. While this is nice, I was a little disappointed that there aren't any test questions for review.

The last chapter details how to deliver a DB2DEMO application. You can download and install this application and explore everything the book covers on SQL (including referential integrity and triggers), advanced object relational features (including user-defined types and functions, SQL/XML and XQuery) and business intelligence features (including star schema support, multi-dimensional analysis and automatic summary tables). Manageability and performance are also covered, with options to compare two different SQL statements and graph the performance data.

The authors understand that to learn and retain what you learn, you need to actually perform the task. To help with this, they have you build a real application. As a DBA you start out with creating the database and the DB2 objects needed for the application (titled, Certification Testing). You'll learn how to alter and maintain these objects just like you would do in real life.

A lot of my time as a DBA is spent on database performance and tuning and maintaining the applications that access the database. But everyone who works with DB2--whether you're a DBA or a developer--should have a basic understanding of how DB2 works and what areas can be tuned. The Monitoring and Tuning chapter looks at this in great detail, providing some tuning guidelines along with a DB2 architectural overview that includes a process model showing the different database components. You'll also learn about query parallelism and memory usage by the different components within the database server.

Once you understand the architecture and components, you must learn how to monitor these components and tune the database server to run smoothly. The performance issue could be in the database configuration, or it could reside in the application accessing the database server. This chapter's Diagnostics and Problem Determination section tells you how to pinpoint problems.

Database performance and tuning is an art that takes years to learn. Because of this, IBM is making DB2 smarter and providing tools within DB2 for self-tuning (aka, autonomic computing). As I read this book I discovered that DB2 now has a autonomic feature for memory management. Instead of you guessing what your configuration settings need to be, a program called STMM will monitor the memory usage on the system and make the database server configuration changes automatically. I'm sure you'll find nuggets of knowledge when you read this for yourself.

As a DBA or developer, there are always times when you need to look up how something works. That's why everyone who works with DB2 9 should have a copy of this book. It's an excellent reference guide that can help you with any DB2 9 for LUW topic.