I was extremely impressed with this little book on Hibernate. First, the author took the trouble to give complete download and setup instructions for the various software packages, something which is rarely done well.
This is particularly important for the HSQLDB database, which is the DB used by this book (and another which I'm reading). This is an excellent open-source DB which is indifferently documented. Not that difficult if you show it's little tricks as Author Elliot has done.
Apart from that the downloadable examples basically work without fiddling (another relative rarity) with one or two exceptions. I used the downloaded code. The code in Chapter 4 wouldn't compile in Eclipse until I deleted the QueryTest2.java file (this makes sense in terms of the chronology of the chapter). I later recopied QueryTest2.java into the Eclipse workspace after the codegen and schema were built.
The second hiccup was in chapter 5, where the mapping file for the Album file used what appears to be an undocumented Hibernate reserved word named POSITION. Once I renamed POSITION to something else the schema operation ran well.
I hope to see more of these books. Small and superbly executed books about a specific tool or closely-related group of tools with a laser-sharp editorial vision of what to include (everything necessary) and no more. The price is right as well.
on 15 September 2007
This book is irritatingly way too long-winded on HSQLDB and Ant, which are not part of Hibernate but have been used in the examples. The author then squeezes major aspects of Hibernate into short examples, and in several places glosses over the details, referring the reader to the Hibernate documentation. I would have found it more helpful to have more information on Hibernate and less on HSQLDB and Ant.