[Qgis-user] QGIS 2.10.1 adding PostGIS Views

James Keener jim at jimkeener.com
Fri Sep 4 05:28:22 PDT 2015


I wonder if we could make use of the stats the query planner uses.

http://www.postgresql.org/docs/9.1/static/monitoring-stats.html

http://www.postgresql.org/docs/9.1/static/planner-stats.html

I don't know how tightly this would couple us to any single version of
postgresql though.

Jim

On 09/04/2015 02:42 AM, Andrea Peri wrote:
> Ho,
> How do qgis to analyze the table to retrieve the unique?
> A loop on every record or a SQL to count distinct ?
> 
> A.
> 
> Il 04/set/2015 08:01, "Bernhard Ströbl" <bernhard.stroebl at jena.de
> <mailto:bernhard.stroebl at jena.de>> ha scritto:
> 
> 
> 
>     Am 03.09.2015 um 23:41 schrieb Sandro Santilli:
> 
>         On Wed, Sep 02, 2015 at 08:48:34AM +0200, Bernhard Ströbl wrote:
> 
>             Am 01.09.2015 um 17:49 schrieb Matthias Kuhn:
> 
> 
> 
>                 2. If there are tables without a PK open a second modal
>                 dialog with an
>                 explanation of the problem and offer to select a pk from
>                 a combobox.
> 
> 
>             I hope you mean "relation" not table, a table should always
>             have a
>             PK.
> 
> 
>         It's not mandatory for a table to have a PK.
>         I guess by "tables without a PK" he means table for which no PRIMARY
>         KEY constraint is explicitly defined (should an UNIQUE key be
>         considered equally valid?).
> 
> 
>     It is not mandatory, of course, that's why I wrote "should", but
>     IMHO it is very bad database design to not define one.
>     There might be several UNIQUE constraints on one table but there can
>     be only one PK constraint. So in case of only a UINIQUE constraint
>     the table would be handled as any other without PK constraint (or
>     QGIS needs to analyse how many fields have a UNIQUE constraint).
> 
>     Bernhard
> 
> 
>     __________ Information from ESET Mail Security, version of virus
>     signature database 12200 (20150904) __________
> 
>     The message was checked by ESET Mail Security.
>     http://www.eset.com
> 
> 
>     _______________________________________________
>     Qgis-user mailing list
>     Qgis-user at lists.osgeo.org <mailto:Qgis-user at lists.osgeo.org>
>     http://lists.osgeo.org/mailman/listinfo/qgis-user
> 
> 
> 
> _______________________________________________
> Qgis-user mailing list
> Qgis-user at lists.osgeo.org
> http://lists.osgeo.org/mailman/listinfo/qgis-user
> 



More information about the Qgis-user mailing list