How to check the PostgreSQL version

The queries below return the PostgreSQL version and information about the installed version.

Version function

Query

select version();

Columns

  • version - postgreSQL version

Rows

  • The query returns just one row

Sample results

Show statement

Query

show server_version;

Columns

  • server_version - version of installed PostgreSQL

Rows

  • The query returns just one row

Sample results

Detailed information

Query

select * from pg_config
where name = 'VERSION'

Columns

  • name - name of the variable
  • setting - value stored in the variable

Rows

  • Query return just one row

Sample results

pgAdmin

In the Browser pane, select our database and then click on the tab Properties to display the PostgreSQL version, along with some system information

Comments are only visible when the visitor has consented to statistics cookies. To see and add comments please accept statistics cookies.
0
There are no comments. Click here to write the first comment.