Skip to content

Commit

Permalink
Restore support for databases without PostGIS installed
Browse files Browse the repository at this point in the history
Closes #34966
  • Loading branch information
strk committed Mar 16, 2020
1 parent fe4b2c8 commit 25b9520
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions src/providers/postgres/qgspostgresconn.cpp
Expand Up @@ -594,12 +594,8 @@ bool QgsPostgresConn::getTableInfo( bool searchGeometryColumnsOnly, bool searchP

QgsDebugMsg( "getting table info from layer registries: " + query );
result = PQexec( query, true );
if ( result.PQresultStatus() != PGRES_TUPLES_OK )
{
PQexecNR( QStringLiteral( "COMMIT" ) );
return false;
}

// NOTE: we intentionally continue if the query fails
// (for example because PostGIS is not installed)
for ( int idx = 0; idx < result.PQntuples(); idx++ )
{
QString tableName = result.PQgetvalue( idx, 0 );
Expand Down

0 comments on commit 25b9520

Please sign in to comment.