[postgis-users] Question on transform.

Frank Warmerdam warmerdam at pobox.com
Wed Oct 2 21:05:24 PDT 2002


Luis Mota wrote:
> Hi everyone.
> 
> I've been using the transform function, but I have some surprising 
> results...
> 
> For instance, if I issue the following query:
> 
> select transform(geomfromtext('POINT(0 38)',4803),4326);
> 
> the result I get is:
>       transform      -----------------------
> SRID=4326;POINT(38 0)
> (1 row)
> 
> ie, exacly the same point... This is obviously wrong, since the two 
> GEOGCS's are different. For instance, the prime meridian is different..
> 
> Is it possible that I have some instalation problem? Was this a bug 
> corrected in a later version?

Luis,

Note that PROJ.4 does not generally have good prime meridian support at this
time.  Sometimes this can be faked by using altered central merdians (for
applicable projected coordinate systems) but the geographic/geodetic
mechanism (+proj=latlong) does not support a prime meridian at this time.

I see in the PostGIS spatial_ref_sys.sql that the PROJ.4 definition for
4803 is just '+proj=longlat +ellps=intl' while the more correct WKT shows
that it should have a lisbon prime meridian.

In short, I don't think you can operate on coordinate systems with
non-greenwich prime meridians properly at this time.

The following bugzilla enhancement request addresses this issue:

   http://bugzilla.remotesensing.org/show_bug.cgi?id=186

There is no schedule for which prime meridian support will be implemented.
Once that is done appropriate updates to the PostGIS spatial_ref_sys.sql
will be required.

Best regards,
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent






More information about the postgis-users mailing list