Fix bloat check to use correct SQL depending on the server version.

Previously it used the psql version which might differ when multiple
versions are installed locally, or when querying remote servers.

The hot_standby_delay check is also affected, but more involved to fix,
so leave that for later.

Adrian Vondendriesch