Discussion:
[Qgis-user] Problem adding WFS Layer
Tim Semmelhaack
2016-04-07 08:51:52 UTC
Permalink
Hi



I try to add a WFS-Layer to QGIS (2.14.1) from a Geoserver (2.7.5)
(Multilinestring) but the lines are going to strange Coordinates.

Loading Image...



The WFS is generated from a Postgis-table.



The Layer Preview in Geoserver looks normal



http://daten.zvbn.de/geoserver/zvbn/wms?service=WMS
<http://daten.zvbn.de/geoserver/zvbn/wms?service=WMS&version=1.1.0&request=G
etMap&layers=zvbn:lin_gis_akt&styles=&bbox=377566.9098,5796988.3156,577312.9
733,5971367.4793&width=768&height=670&srs=EPSG:32632&format=application/open
layers>
&version=1.1.0&request=GetMap&layers=zvbn:lin_gis_akt&styles=&bbox=377566.90
98,5796988.3156,577312.9733,5971367.4793&width=768&height=670&srs=EPSG:32632
&format=application/openlayers



Any ideas?



Tim
Lene Fischer
2016-04-07 09:02:10 UTC
Permalink
Hi Tim,
What about your projection EPSG in the database - are they the same?
In my settings I have set CRS to "Promt for CRS for new layers" then I can choose the right projection.

Regards
Lene Fischer

Fra: Qgis-user [mailto:qgis-user-***@lists.osgeo.org] På vegne af Tim Semmelhaack
Sendt: 7. april 2016 10:52
Til: qgis-***@lists.osgeo.org
Emne: [Qgis-user] Problem adding WFS Layer

Hi

I try to add a WFS-Layer to QGIS (2.14.1) from a Geoserver (2.7.5) (Multilinestring) but the lines are going to strange Coordinates.
http://daten.zvbn.de/files/qgis_wfs.png

The WFS is generated from a Postgis-table.

The Layer Preview in Geoserver looks normal

http://daten.zvbn.de/geoserver/zvbn/wms?service=WMS&version=1.1.0&request=GetMap&layers=zvbn:lin_gis_akt&styles=&bbox=377566.9098,5796988.3156,577312.9733,5971367.4793&width=768&height=670&srs=EPSG:32632&format=application/openlayers

Any ideas?

Tim
Christophe Damour
2016-04-07 12:53:20 UTC
Permalink
Hi,

Sorry for double posting, but my first message is waiting for moderation
because of attach file size...

I am trying to import a PostGis layer into a SpatiaLite database, using
QGIS Database Manager import function.

The PostGis layer has a string primary key, and I want to keep that
primary key.

To keep the primary key, I check "Primary key" option and type the name
of the PostGis primary key field, but the result is an empty column...
I tried to workaround this problem by keeping primary key values in a
second column and getting them back after the import, this used to work
with QGIS V2.8, but doesn't anymore with QGIS V2.14.

Here is the result I get :
- When opened in QGIS Database Manager, I can see correct values in the
id column.
- When opened in QGIS, every record has the same id value.

So my questions are :
- Why isn't it possible to keep PostGis primary key when importing to
SpatiaLite with QGIS Database Manager ?
- How to workaround this problem ?

Thank you for helping,
--
Christophe
Hi,
I am trying to import a PostGis layer into a SpatiaLite database,
using QGIS Database Manager import function.
The PostGis layer has a string primary key, and I want to keep that
primary key.
To keep the primary key, I check "Primary key" option and type the
name of the PostGis primary key field, but the result is an empty
column...
I tried to workaround this problem by keeping primary key values in a
second column and getting them back after the import, this used to
work with QGIS V2.8, but doesn't anymore with QGIS V2.14.
Attached to this message is an example SpatiaLite database that
- When opened in QGIS Database Manager, I can see correct values in
the id column.
- When opened in QGIS, every record has the same id value.
- Why isn't it possible to keep PostGis primary key when importing to
SpatiaLite with QGIS Database Manager ?
- How to workaround this problem ?
Thank you for helping,
--
Christophe
Loading...