10

Most of my experience with PostgreSQL has been pgAdminIII and psql, but I'm interested to know what others use.

Is there PostgreSQL equivalent to SQL Server Management Studio (SSMS) and its ability to display, in a limited way, results containing geometry (free or paid)?

Or do most people just run a GIS client on the side for this purpose, as this question seems to indicate: GUI tools for PostgreSQL/PostGIS??

I looked down through the PostgreSQL software catalog, but I didn't find anything (other than broken links).

Andre Silva
10.5k12 gold badges57 silver badges109 bronze badges
asked Dec 9, 2013 at 14:16
4
  • It may not matter to you, but what operating system are you currently using? Commented Dec 9, 2013 at 16:42
  • typically windows at work / mac at home. Commented Dec 9, 2013 at 19:29
  • 1
    I mostly use QGIS on Ubuntu as my sql spatial client, when I need to see the results after running / construcing a query Commented Dec 13, 2013 at 22:38
  • Out of interest, what can't you do in QGIS that you regularly would need to do on your database, given that you can run all kinds of SQL directly using the Database Manager? Commented Dec 14, 2014 at 15:45

2 Answers 2

6

pgAdmin 4 has now a Geometry Data Viewer since version 4.3.3 (release date: sept/2018; see pgAdmin release notes).

PostGIS extension needs to be enabled in the PostgreSQL database. The Geometry Data Viewer will display results on a map canvas from queries returning geometry and geography columns. If the SRID is 4326 results will be displayed over an OpenStreetMap background map.

See one example:

SELECT * FROM geo.country; -- querying a table named 'country' in schema 'geo'.

The query returns a table with a geometry column. Line 1 is the administrative boundary from Brazil. The button inside the red circle enables the Geometry Data Viewer.

enter image description here

The geometry is displayed in an empty canvas if the coordinate system is different from SRID 4326.

enter image description here

SELECT ST_Transform(geom, 4326) FROM geo.country; -- transform coordinates to SRID 4326.

Now the same result, but with coordinates transformed to SRID 4326 and with a background OpenStreetMap.

enter image description here

answered Oct 25, 2018 at 16:06
5

While I have not actually installed it, I had read about the pgAdmin plugin called "PostGIS viewer" (Windows only) referenced here (2010). The first request to add something like this (that I found) was ticket #485.

Germán Carrillo developed a multiplatform "PostGIS viewer" based on PyQGIS. You can access old versions here, here, and here, all from 2011. The latest version (2012) uses the QGIS plugin "Fast SQL Layer", and includes detailed installation instructions for Windows and Linux.

answered Dec 9, 2013 at 16:50
1
  • Just to add that with the PyQGIS-based PostGIS viewer you can build new geometries with SQL queries as well as view PostGIS raster layers. Commented Dec 14, 2014 at 19:56

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.