[Qgis-user] Strange behaviour importing data from postgis

Igor Sosa Mayor joseleopoldo1792 at gmail.com
Mon Feb 23 13:59:33 PST 2015


Bo Victor Thomsen
<bo.victor.thomsen at gmail.com> writes:

> Igor -
>
> Yes, the splitting of a table in several parts in QGIS , each
> containing only one type of geometry objects is standard behaviour.
>
> A workaround is to change all your "single"-point/line/polygons to
> multi-point/line/polygons with an update command in the postgis table.
> I suspect there is a slight performance degradation using this method,
> but all your rows in the table will be represented in a single layer
> in QGIS.
>
> Regarding your point table:
>
> * Does all your records in the point table actually have point object,
>   i.e.none of the records contains NULL in the geometry column ? 
> * Is your primary key for the table an integer value ? (QGIS needs a
>   integer unique key for the table. The simplest method to ascertain
>   this is to have an integer primary key for the table.)

Thanks again for your answer.

I think I have to apologize. Maybe it was something wrong with the db. I
deleted it, imported all the data again and it works.

Nevertheless I'm a little bit confused by this question about the
primary key. The import made by osm2psql does not create any primary key
in the points table. However QGIS does not have any problems in
importing the data (it seems...).

In any case: thanks again for your time/help.

Regards,


-- 
:: Igor Sosa Mayor     :: joseleopoldo1792 at gmail.com ::
:: GnuPG: 0x1C1E2890   :: http://www.gnupg.org/      ::
:: jabberid: rogorido  ::                            ::




More information about the Qgis-user mailing list