[postgis-users] prj and SRID relation

Paul Ramsey pramsey at refractions.net
Thu Oct 14 07:17:59 PDT 2004


Your problem is not postgis support (or lack thereof) of prj files, it 
is how the DI Extension is inserting the projection information and 
reading it back from PostGIS. The DI extension is actually based on 
code from Safe software, perhaps someone (Ryan?) from there could 
comment.

In general, our own tools (shp2pgsql, pgsql2shp) could start to 
recognize .prj information for import and export, but that would 
require a means of parsing and using the WKT contained therein, which 
would entail either (a) writing our own WKT projection handling code 
(b) adding a dependency on OGR, which has decent WKT handling code or 
(c) porting the OGR WKT code over the proj4 so that we only have one 
dependency still for reprojection.  Of the set, I find (c) the least 
unappealing, but even it is quite unappealing (and quite hard, since 
the OGR code is C++ and proj4 is C, the "port" would essentially be a 
guided re-write).  An advantage of having real WKT support would be 
that we could retire the nonstandard PROJ4TEXT column in our 
SPATIAL_REF_SYS table and stop ignoring the SRTEXT column.

On 13-Oct-04, at 8:30 PM, Christopher Pedrezuela wrote:
>
> Just would like to ask if postgis supports ESRI’s prj files. I noticed 
> when I exported a shp file into a postgis table, using ESRI’s DI 
> Extension, its datum in the spatial reference table is “unnamed”. As a 
> result, when importing from a postgis table back to a shape file, 
> arcmap does not also recognize the datum that the feature originally 
> had. Is there a way to correct this.




More information about the postgis-users mailing list