Dbeaver Like



What is the best alternative to DBeaver? SchemaSpy has no methods for dealing with when you only have a schema generated via something like (mysqldump -no-data options schema-onlydump.sql), and do not currently have access to a live database to connect with. Just tested DBeaver 7.2.5 on a MacBook Air M1 with BigSur 11.0.1 and it doesn't start. Seems like the first time it ran Rosetta2 but doesn't produce any output. Open to helping out with testing to support this as a Universal app or a working Rosetta2 translation.

PostGIS users have a new option for viewing spatial data!DBeaver has joined the spatial database club with itsgeometry viewer, available sinceversion 6.0.3.I previously wrote aboutPgAdmin4's geometry viewer,now we have two general purpose database GUI options supportingPostGIS spatial data. This post gives an overview ofDBeaver's implementation and my initial thoughts.

This post was written using DBeaver v6.1.0, PostgreSQL 11.3, and PostGIS 2.5.

What it looks like

DBeaver's geometry viewer allows you to easily select and displaya single row, multiple rows, or all rows with relative ease. This ishandled by you selecting one or more rows of spatial data. Clickingthe spatial column's header displays all returned rows.

This query was used in the PgAdmin4 post, it findstrees within 25 meters ofPangea Coffee Roastersin Golden, CO.

Not only SRID 4326

Dbeaver Like Query

Dbeaver sql like

The query above uses ST_Transform(n.way, 4326) to convert thespatial data toSRID 4326, or WGS-84.I started with that transformation because PgAdmin's geometry viewerrequires it in that projection to render over OpenStreetMap data.

This is not a requirement in DBeaver's implementation! Check it out,if we transform to SRID 3857 (change to ST_Transform(n.way, 3857),it looks pretty much the same. Look closely though, there aretwo (2) subtle differences. First, just below the map now reads EPSG:3857 instead of EPSG:4326.This is a good indicator to keep your eye on.Second, the data in the way_tree column of the grid now hasnumeric values like -11713414.94 instead of-105.22339669.

What about 900913

Another common SRID used is 900913 and happens to be the formatour OpenStreetMap data is stored in, as the comments in theabove queries indicate. This is the formatosm2pgsql uses by defaultand I haven't had any reason to change it.

Dbeaver Like

What happens if we try to visualize some spatial data inSRID 900913 without using ST_Transform?DBeaver detects it (see EPSG:900913 below the map area),but apparently it doesn't know how to handle the data properly andinstead displays as a line.

Don't worry though, there's an easy workaround to this! To the rightof the EPSG:900913 there's a little click-able down-arrow.Click that down arrow, select EPSG:3857, and we are back on themap!

This is handy because while the syntax for ST_Transformis straight-forward, we like to be lazy whenever possible!In mypost on PgAdmin4's geometry viewerI explain why a lightweight, speedy, efficient GUI option wasimportant to PostGIS administrators.

Another benefit by not requiring ST_Transform is that functionrequires CPU on the server. By not having to transform the datait should be little more CPU friendly for yourPostGIS / PostgreSQL servers.

Getting all the data

Like

The above screenshot showed only some of the data for the southernarea of Colorado being returned. This is because DBeaver limits the number of rowsreturned by default. You can fetch all easily with the controlat the bottom of the window.

You should get the warning that you might need to go make some coffee.

Overall impression

DBeaverhas done a stellar job with their geometry viewer implementation!Since I first installed the initial version having this feature (6.0.3)I have largely stopped using PgAdmin in favor of DBeaver.DBeaver is currently my go-to choicefor quickly exploring, visualizing and administering our PostGIS data.

Of course I still use psql significantly more... 😏

Dbeaver Like Linux

Need help with your PostgreSQL servers or databases?Contact usto start the conversation!

Like

Dbeaver License Cost

By Ryan Lambert
Published June 13, 2019
Last Updated June 13, 2019