Whilst I was in Britain in September, I got the chance to visit a book store with my wife and because of the limited number of books and the fact I needed something on the subject, I grudgingly picked up Sams Teach Yourself SQL in 24hrs, 3rd Edition and Sams Teach Yourself SQL in 10 Minutes.
I say grudgingly because I’ve never been a fan of these books, but to date had never actually read one. My opinions here-to-fore where based on quick flick throughs at the book store.
The book uses MySQL as its example database server. Almost.
This is my biggest grudge with the book, the authors are both Oracle users and are quite biased towards Oracle; this is fine, except for the fact that they advocate the use of MySQL to test with and then never show MySQL specific implementations of stuff.
For example, they show how to do Math functions in SQL Server, Sybase and Oracle but not MySQL. They have a funny little graphic, a sort of grey box with the word MySQL in it, and a horizontal line through it to mean that the current part is not MySQL compatible.
Don’t you think rather than (or at least, in addition to) they might have gone to the effort of researching their example RDBMS and put in relavant examples?
Other than this, the coverage of the ANSI SQL Standard is quite good.
Personally, I preferred Sams Teach Yourself SQL in 10 Minutes. It doesn’t cover as much, but it covers just about everything you should know and uses MySQL and PgSQL for example implementations and where possible (i.e. they support it) shows examples using the SQL standard and the MySQL/PgSQL “proprietary” standards. This is the book I keep by my monitor for reference. Its also only about $20.
I think I’ll leave the other one at work… for emergencies. Like if I need a foot rest in a hurry.