Fixed minor issues with PostgreSQL 9.3