I had Postgres version 13 installed on my windows machine. I've upgraded to version 14 and left the old version there. I've updated my path variable to the new version.
In PGAdmin 4 I created a new database called education_system
and can use it there. But when I log into the psql
command line I only see the old databases I had under 13 and not the one I created under PGAdmin 4 under version 14.
If I check the version on the command line it shows the correct version:
psql -V
psql (PostgreSQL) 14.1
But when I log into psql it shows that I am on the cli version 14.1 but the server version 13.2
psql -U postgres
Password for user postgres:
psql (14.1, server 13.2)
Listing the databases shows only the ones I had under version 13
postgres=# \l
List of databases
Name | Owner | Encoding | Collate | Ctype | Access privileges
-------------------+----------+----------+----------------------------+----------------------------+-----------------------
analysis | postgres | UTF8 | English_United States.1252 | English_United States.1252 |
animals | postgres | UTF8 | English_United States.1252 | English_United States.1252 |
aws_inventories | postgres | UTF8 | en_US.UTF-8 | en_US.UTF-8 |
azr_inventories | postgres | UTF8 | en_US.UTF-8 | en_US.UTF-8 |
gcp_inventories | postgres | UTF8 | en_US.UTF-8 | en_US.UTF-8 |
postgis_31_sample | postgres | UTF8 | English_United States.1252 | English_United States.1252 |
postgres | postgres | UTF8 | English_United States.1252 | English_United States.1252 |
template0 | postgres | UTF8 | English_United States.1252 | English_United States.1252 | =c/postgres +
| | | | | postgres=CTc/postgres
template1 | postgres | UTF8 | English_United States.1252 | English_United States.1252 | =c/postgres +
| | | | | postgres=CTc/postgres
(9 rows)
And the education_system
database is nowhere to be found. How can I get the server version to match the version I have on the command line?
ALTER DATABASE template1 REFRESH COLLATION VERSION