[postgis-users] architectural status of shp2pgsql?

strk at refractions.net strk at refractions.net
Sun Jul 3 10:38:21 PDT 2005


On Sun, Jul 03, 2005 at 09:59:50AM -0700, gold wrote:
> shp2pgsql is nice, but i'm either going to radically modify my local 
> version, or cut something new, and i'm wondering if there is any planned 
> or ongoing work to that effect?
> 
> in particular, i'd like to see the functionality split a bit, as well as 
> some things added:

What revision are you using ?
I've put some efforts to split functionalities a bit in recent ones.

> * split up the metadata sniffing/table creation part into a separate module
> 
> * use this module in two places -- shp2pgsql and dbf2pgsql (to be 
> created). i realize (from the discussion in march, i think) that there 
> is a dbf2pg in the postgres contrib, but it's not much to my liking. 
> also, i'd like to have shp2pgsql and dbf2pgsql running off of a common 
> io and metadata core.

My proposal was to let shp2pgsql read .dbf files w/out corresponding
shp in case shp were missing.

> * add projection (.prj) capabilities to shp2pgsql.
> 
> are there already efforts to do this stuff, or, if not, and i end up 
> doing the work, are there people out there willing to do code reviews 
> and provide some other guidance?

There are no efforts I'm aware of. I think main problem would be
finding a match or create a new record in spatial_ref_sys.
Maybe first step should be some utility functions to query spatial_ref_sys
given a set of definitions. What does .prj files contain ?

-strk;



More information about the postgis-users mailing list