3

In QGIS add vector layer creates a layer with 3D geometry. All my postGIS tables have been created with 2D so I can not save them to PostGIS.

Are there any problems with converting my existing 2D tables to 3D to get around this?

I am aware that QGIS 3 will allow one to drop the z dimension but this question is explicitly about converting tables to 3D.

7
  • 1
    Your question is about creating new layers in postgis but using existing ones from postgis. There seems to be a mismatch here. Do you mean using and editing existing postgis layer from QGIS?
    – tilt
    Jun 26 '17 at 8:23
  • Furthermore I don't see problems with converting existing 2D tables to 3D, but I'm a little surprised this is needed with QGIS.
    – tilt
    Jun 26 '17 at 8:24
  • I am importing data from a GPS into QGIS and then adding it a master layer that is backed by PostGIS. When I try and save the updated master I get errors about the 3D data. Jun 27 '17 at 23:22
  • What do you mean with 'a master layer that is backed by PostGIS'. Is it a postgis layer or is it something else? Do you create that master layer yourself or is it already there? Please describe step-by-step what you are doing.
    – tilt
    Jun 28 '17 at 12:01
  • it is a vector layer which is defined by an sql query on a PostGIS db. It contains all my waypoints -- I have another that contains all lines. The problem comes when I try to save the updated vector layer to PostGIS. QGIS 3 will deal with this but in the mean time it is painful. Jun 29 '17 at 20:41
1

There is no problem with converting your existing 2D tables to 3D, apart from your data becoming slightly larger with an extra z-coordinate (with value 0) attached to it.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.