Chapter 12. Miscellaneous SQL Topics

I explained that we are calling the White Paper “Open Government” because you always dispose of the difficult bit in the title. It does less harm there than on the statute books.

Sir Humphrey Appleby, in Open Government (first episode of the BBC TV series Yes Minister, by Antony Jay and Jonathan Lynn, 1981)

This last chapter is something of a potpourri; it discusses a few SQL features that, for one reason or another, don’t fit very neatly into any of the previous chapters. It also gives a simplified BNF grammar for SQL table expressions and SQL boolean expressions, for purposes of reference.

Also, this is as good a place as any to define two terms that you need to watch out for. The terms in question are implementation defined and implementation dependent, and they’re both used heavily in the SQL standard. Here are the definitions:

Definition: An implementation defined feature is one whose semantics can vary from one implementation to another, but do at least have to be specified for any individual implementation. In other words, the implementation is free to decide how it will implement the feature in question, but the result of that decision must be documented. An example is the maximum length of a character string.

Definition: An implementation dependent feature, by contrast, is one whose semantics can vary from one implementation to another and don’t even have to be specified for any individual implementation. In other words, the term effectively ...

Get SQL and Relational Theory, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.