Bug report #5052
When adding PostGIS table, QGIS hangs because of expensive queries on views
Status: | Closed | ||
---|---|---|---|
Priority: | Normal | ||
Assignee: | - | ||
Category: | GUI | ||
Affected QGIS version: | master | Regression?: | No |
Operating System: | Easy fix?: | No | |
Pull Request or Patch supplied: | No | Resolution: | worksforme |
Crashes QGIS or corrupts data: | No | Copied to github as #: | 14822 |
Description
If you click Add a PostGIS Layer and connect to a database with large views, QGIS will hang for a long time, even though the Add PostGIS Table(s) dialog still appears responsive, because QGIS is doing expensive queries on the database.
I don't think expensive queries should be run on views by default. The default behavior should require some kind of consent, either a global setting to QGIS or me selecting the view in the dialog, before expensive queries are run.
I have views with several hundreds of thousands of rows.
History
#1 Updated by Jürgen Fischer almost 13 years ago
- Resolution set to worksforme
- Status changed from Open to Closed
enable "Use estimated metadata" in your postgresql connection.