[postgis-tickets] [PostGIS] #3682: Strange fieldlength in result of pgsql2shp

PostGIS trac at osgeo.org
Thu Dec 22 05:07:46 PST 2016


#3682: Strange fieldlength in result of pgsql2shp
---------------------------+---------------------------
 Reporter:  postgispaul    |      Owner:  robe
     Type:  defect         |     Status:  new
 Priority:  medium         |  Milestone:  PostGIS 2.3.2
Component:  loader/dumper  |    Version:  2.0.x
 Keywords:                 |
---------------------------+---------------------------
 When I export a query to a shapefile, boolean columns are converted to
 logical fields with a length of 2.

 Don't know if it is allowed by the shape/dbf specs, but arcgis isn't able
 to open them.
 Other tools (f.e. qgis) are opening them correctly though

 it's this piece in http://svn.osgeo.org/postgis/trunk/loader/pgsql2shp-
 core.c
 if (pgfieldtype == 16)
 {
  dbffieldtype = FTLogical;
  dbffieldsize = 2;
  dbffielddecs = 0;
 }

 Any particular reason for setting the length to 2?
 Svn history didn't show any changes there since the file was added.

--
Ticket URL: <https://trac.osgeo.org/postgis/ticket/3682>
PostGIS <http://trac.osgeo.org/postgis/>
The PostGIS Trac is used for bug, enhancement & task tracking, a user and developer wiki, and a view into the subversion code repository of PostGIS project.


More information about the postgis-tickets mailing list