Provides exactly what it promises
I bought this guide because I needed a quick lookup for XML schema elements (something you'd think would be readily available online, but isn't - at least not in a usable form). The bulk of the book (70 of its 162 pages - about half) is dedicated to XSD, so I was very happy with what I got. The first 30 pages cover XML itself (all the nitpicking details like predefined entities, what characters are allowed in attribute names, etc). The next 17 pages cover DTD (which you may occasionally still need to know, even these days). The next 70 cover XML Schema, and the book finishes up with an additional 43 pages on Relax-NG and Schematron (two competing, and not very common, schema definition formats).
I agree with other reviewers that the book would have been complete without the Relax-NG and Schematron coverage, but it would have just been 43 pages shorter if that was the case - there's really not much else they could have said about XML, DTD and XSD and still have been a concise "pocket reference". This book is actually pretty thick for an O'Reilly pocket reference - I have four other pocket guides on my bookshelf right now, and the other three have 120, 124 and 66 pages each. By that standard, I figure the coverage of Relax-NG and Schematron were just a "buy one get one free" type of add-on, especially since this book costs the same as all the other pocket reference books.
This book is a perfect reference for somebody who needs a quick, handy reference to XML schema and the occasional XML rule.
Another view
I am one of the coauthors of this book. I feel compelled to write a review in support of my friend and coauthor, Simon St. Laurent, who wrote the section on XML Schema. Of the 160 pages of text in XML Pocket Reference, Third Edition, 71 pages are dedicated to XML Schema. That's 44 percent of the book. Of the 71 pages, 16 pages cover examples of XML Schema.
DTDs are covered in 15 pages, RELAX NG in 32, and Schematron in 10 (57 pages total). XML Schema receives the most extensive treatment of any of the topics covered, and within the limitations of the size of the book, Simon did an excellent job.
XSLT and XPath were not included in this book because a new, separate volume has been dedicated to those topics-XSLT 1.0 Pocket Reference, by Evan Lenz, which also appeared in August 2005.
As for the production rules, they were included for programmers and others who need grammars. The productions, which come from the XML spec, are a means for understanding XML syntax precisely, and it would have been unwise, in my view, to omit them.
Good and Not-So-Good
My problem with this book is that I was hoping it would concentrate more on just XML Schema, something I think most people would prefer. Of course, how I am qualified to make that kind of statement is beyond me ;-) But here is my reasoning: A fairly large portion of the book covers DTDs, RELAX NG, and Schematron. DTDs, while ubiquitous, are being supplanted by XML Schema. Usage of RELAX NG and Schematron are, by the book's own admission, not widespread. So it seems that all three of these technologies could have been admitted, as were many other XML-related technologies (XSLT, XPath, etc.)
In addition, I feel the regular-expression-like inclusions should have been omitted. These include something referred to as Productions in one part of the book and Contents in another. Maybe good for hard-core CS people, but pretty much useless for those of us who just want to work with XML Schema. An ideal replacement would have been some examples illustrating sample usage of various elements and attributes.
All in all, the descriptions accompanying the elements and attributes are pretty good. Unfortunately, that accounts for only about one-third of the book. But it only costs $10 and it is small, so maybe it's worth it.
Depends on what you're looking for...
The other review book I received yesterday was XML Pocket Reference (3rd Edition) by Simon St. Laurent and Michael Fitzgerald. Depending on what you're looking for, this may or may not the book for you...
Contents: Introduction; XML Structures; Document Type Definitions; W3C XML Schema; RELAX NG; Schematron; XML Specifications; Index
Admittedly, trying to cover "XML" in a single book is a daunting task. XML is made up of so many standards and technologies (XPath, XForms, XML Schema, etc.) that you either have to specialize your coverage area or be ready to publish a *really* heavy book. To their credit, the authors stripped out XSLT into it's own pocket guide. That act keeps this particular book small enough to fit in your pocket and that's good. But if you're wanting information on XSLT and think this might be your book, forget it.
Next, the XML Structures and Document Type Definition chapters seemed to be a little confusing. There was something introduced that I had never heard of before... something called "Productions" followed by syntax that looked like regular expression language. Never having seen that term before in my XML reading, I went back to the introduction to see what the authors wanted to convey there. The only explanation was "As each structure is discussed, applicable productions from the XML 1.0 and 1.1 specs will be listed in the order in which they appear in the specs." So, I still really don't know what productions are, and I probably have to go to the specs to find that out. The description of each section in an XML document, like CDATA or declarations, was nice though.
The book starts to become really useful when you get into the XML Schema section. There they go into each of the elements along with each attribute that can be used with the element. This is the type of reference information I'd expect to see in a pocket guide. Something I can turn to quickly as a refresher for what parameters or attributes I can use with an element, or to gain a quick understanding of an element I haven't seen before. This same structure is followed for the RELAX NG and Schematron schema languages, so the book will be helpful if you live in those worlds also.
Basically, I found the XML Pocket Guide to be a little "hit and miss". If the title had been "XML Schema Pocket Guide", I'd have felt like the book was pretty on target. Trying to call it the XML Pocket Guide seems to infer there's a lot more in here than there actually is, and a buyer might get a copy and be highly disappointed in what it doesn't cover. If you're looking for schema info, you'll love the book. If that's a secondary reason for you to get the book, you might be disappointed.
Lots about the schema
The majority of the new material in this book is on different schema specifications. Schema, Relax NG and Schematron are covered. A handy book to have around when you are hacking XML. The online free documentation is not as handy as the content as it's organized in this book.