Fix psql for atomicity, sql for modernity