Case sensitivity rules haven't changed but the handling of tablename.type
has changed in PostgreSQL 9.1. The catch is that name
is a postgres built-in type, used for the catalog.
Here's the relevant entry in the 9.1 release notes:
E.14.2.2. Casting
Disallow function-style and attribute-style data type casts for composite types (Tom Lane)For example, disallow composite_value.text and text(composite_value). Unintentional uses of this syntax have frequently resulted in bug reports; although it was not a bug, it seems better to go back to rejecting such expressions. The CAST and :: syntaxes are still available for use when a cast of an entire composite value is actually intended.
My guess would be that your table template_role
doesn't have a name
column in 9.0, and that having tmplRole.name
being interpreted as tmplRole::name
was a bug was went unnoticed in your query.
Also see the related Is name a special keyword in PostgreSQL?