[postgis-tickets] [PostGIS] #2623: pgsql2shp creates a dbf with 0 records when the table only has a geometry column

PostGIS trac at osgeo.org
Tue Apr 29 04:46:51 PDT 2014


#2623: pgsql2shp creates a dbf  with 0 records when the table only has a geometry
column
---------------------+------------------------------------------------------
 Reporter:  winkey   |       Owner:  pramsey      
     Type:  defect   |      Status:  new          
 Priority:  medium   |   Milestone:  PostGIS 2.2.0
Component:  postgis  |     Version:  2.0.x        
 Keywords:           |  
---------------------+------------------------------------------------------

Comment(by landry):

 hexdump of the empty dbf for the source shapefile
 {{{
 0000000 7203 1802 0004 0000 0021 0001 0000 0000
 0000010 0000 0000 0000 0000 0000 0000 0300 0000
 0000020 200d 2020 0020
 0000025
 }}}
 full pgsql2shp command:
 {{{
 pgsql2shp -r -f armoire_43 -h services -u postgis postgis "select t.* from
 erdf_armoires_simples_hta_2014 as t, communes_2154 as c where
 st_intersects(t.the_geom,c.the_geom) and c.insee_dept='43'"
 Preparing table for user query... Done.
 Initializing... Done (postgis major version: 1).
 Output shape: Point
 Dumping: XX [1 rows].
 }}}
 hexdump of the empty dbf file generated by the command
 {{{
 0000000 5f03 1a07 0001 0000 0041 000c 0000 0000
 0000010 0000 0000 0000 0000 0000 0000 0000 0000
 0000020 4947 0044 0000 0000 0000 4e00 0000 0000
 0000030 000b 0000 0000 0000 0000 0000 0000 0000
 0000040 200d 2032 2020 2020 2020 2020 0020
 }}}

-- 
Ticket URL: <http://trac.osgeo.org/postgis/ticket/2623#comment:4>
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