fix bug 1095584 - Fix tests when using PostgreSQL
Merge pull request #12 from jwhitlock/1095584_postgres_tests

fix bug 1095584 - PostgreSQL fixes