Programming the Perl DBI
Author: Alligator Descartes and Tim Bunce
Publisher: O'Reilly & Associates
Price: $34.95 US
Reviewer: Bill Cunningham
This new book from O'Reilly is the first one available from any publisher on the subject of programming the Perl DBI, and its authors are imminently qualified to write it. Tim Bunce wrote the DBI Perl module, and also the DBD Oracle module. Alligator Descartes, who originally began working on the book, is a leading Perl/DBI exponent in the Oracle community. The authors have been working on the Perl interface to relational databases, and documentation thereof, since 1992. Programming the Perl DBI is not merely a republication of older documentation. A great deal of new material is here, not all of it about DBI.
The book starts out very simply, describing how even a flat file like /etc/passwd can be a bona fide database. The authors progress logically to more complex data models by addressing the shortcomings of the simpler models. After flat files, the book covers DBM and the Berkeley Database Manager, again noting the details of use, pros, cons and applications where this type of database is best used. A chapter on SQL and relational databases is included as a primer for those who are new to the material.
Three chapters deal with the theory and practice of using DBI to interact with various relational database engines. One chapter is devoted to ODBC. Every DBI method is described in detail and illustrated with at least one code example. There is also a chapter on DBISH, the DBI shell, wherein one can interactively give commands to the database after the manner of Oracle's SQLPlus. This tool will be valuable during development of database programs.
The book includes a description of a complex relational model where Microsoft clients access UNIX servers and vice versa over a network, with data encrypted via software.
The appendices contain a complete DBI specification, and specific information for each of the major relational engines.
The authors assume the readers have significant fluency with Perl, including installation and use of Perl modules and Perl's object-oriented syntax. Although the code examples are short, numerous and well-documented, readers new to Perl may need a Perl reference as they go through the code.
As a one-source database reference, the book is essentially complete. Detailed treatment is given to the DBI/DBD concept where each database engine has a unique driver (DBD), and a DBI superlayer that provides transparency to the engine below. All of the DBI methods are covered in detail, so the reader is able to select methods appropriate to his or her programming tasks. The authors are especially thorough in their treatment of debugging levels, error trapping and error interpretation.
They state that DBI is very much a work in progress and envision it to be a full-featured product soon, on par with any commercial development product available.
I noticed only two minor typos in the entire book. This was quite refreshing to me, as I have read computer books containing so many errors as to be virtually useless.
Anyone who works with data will find this book useful. And the more closely one works with relational databases and the programs which access that data, the more useful it will be.
Webinar: 8 Signs You’re Beyond Cron
On Demand NOW
Join Linux Journal and Pat Cameron, Director of Automation Technology at HelpSystems, as they discuss the eight primary advantages of moving beyond cron job scheduling. In this webinar, you’ll learn about integrating cron with an enterprise scheduler.View Now!
|Dr Hjkl on the Command Line||May 21, 2015|
|Initializing and Managing Services in Linux: Past, Present and Future||May 20, 2015|
|Goodbye, Pi. Hello, C.H.I.P.||May 18, 2015|
|Enter to Win Archive DVD + Free Backup Solution||May 18, 2015|
|Using Hiera with Puppet||May 14, 2015|
|Urgent Kernel Patch for Ubuntu||May 12, 2015|
- Dr Hjkl on the Command Line
- Initializing and Managing Services in Linux: Past, Present and Future
- Goodbye, Pi. Hello, C.H.I.P.
- Enter to Win Archive DVD + Free Backup Solution
- Using Hiera with Puppet
- Gartner Dubs DivvyCloud Cool Cloud Management Vendor
- Infinite BusyBox with systemd
- Mumblehard--Let's End Its Five-Year Reign
- A More Stable Future for Ubuntu
- It's Easier to Ask Forgiveness...