956266 - Fixing bad content views SQL statement

Fixing SQL statement in content views that works in PostgreSQL 9 but not in
PostgreSQL 8.