[postgis-users] Invalid SRID for geography type: ee4

Philippe watcherfr at gmail.com
Wed Apr 11 12:36:49 PDT 2012

Thanks for the feedback regarding 4326.

>You can't load projected coordinates into geography, you'll need to
>load to geometry, then re-project to 4326 and cast to geography if you
>really want to use geography (why do you want to if your data is all
>neatly contained in Belgium and already projected?)
I have data throughout the world and I then associate it with
administrative boundaries using shapefiles from various sources including
IGN France, IGN Belgium, OSM, etc...

I was under the impression that geometry was only to be used over small
areas. Am I wrong ? Should I really be using geometry and not geography ? I
usually use ST_covers and plane to use ST_intersection and ST_area


2012/4/10 Philippe <watcherfr at gmail.com>

> Hello,
> I'm running into an issue loading data from the Belgium IGN.
> I can transform a shapefile into Postgis loadable data with Geometry but
> not Geography. I can't imagine why. Any ideas ? Thanks
> The following works
> /usr/lib/postgresql/9.1/bin/shp2pgsql -WLATIN1 -s3812 -d -I
> /home/postgres/warehouse/shapes/BE/vector/Shape_L08/commune_polygon.shp
> be_ign > /tmp/be_ign.sql
> The following fails
> /usr/lib/postgresql/9.1/bin/shp2pgsql -WLATIN1 -s3812 -G -d -I
> /home/postgres/warehouse/shapes/BE/vector/Shape_L08/commune_polygon.shp
> be_ign > /tmp/be_ign.sql
> with
>        "Shapefile type: Polygon
>        Postgis type: MULTIPOLYGON[2]
>        Invalid SRID for geography type: ee4"
> Although 0xee4=3812 which is the EPSG for the Lambert 2008 projection used
> by that file. And my spatial ref table contains it:
> public=# select * from spatial_ref_sys  where auth_srid=3812;
> srid      | 3812
> auth_name | EPSG
> auth_srid | 3812
> srtext    | PROJCS["ETRS89 / Belgian Lambert
> 2008",GEOGCS["ETRS89",DATUM["European_Terrestrial_Reference_System_1989",SPHEROID["GRS
> 1980",6378137,298.257222101,AUTHORITY["EPSG","7019"]],AUTHORITY["EPSG","6258"]],PRIMEM["Greenwich",0,AUTHORITY["EPSG","8901"]],UNIT["degree",0.01745329251994328,AUTHORITY["EPSG","9122"]],AUTHORITY["EPSG","4258"]],UNIT["metre",1,AUTHORITY["EPSG","9001"]],PROJECTION["Lambert_Conformal_Conic_2SP"],PARAMETER["standard_parallel_1",49.83333333333334],PARAMETER["standard_parallel_2",51.16666666666666],PARAMETER["latitude_of_origin",50.797815],PARAMETER["central_meridian",4.359215833333333],PARAMETER["false_easting",649328],PARAMETER["false_northing",665262],AUTHORITY["EPSG","3812"],AXIS["X",EAST],AXIS["Y",NORTH]]
> proj4text | +proj=lcc +lat_1=49.83333333333334 +lat_2=51.16666666666666
> +lat_0=50.797815 +lon_0=4.359215833333333 +x_0=649328 +y_0=665262
> +ellps=GRS80 +units=m +no_defs
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/postgis-users/attachments/20120411/a647fb6b/attachment.html>

More information about the postgis-users mailing list