[postgis-users] Google Mercator and PostGIS under Ubuntu

Paragon Corporation lr at pcorp.us
Wed Nov 19 23:48:32 PST 2008


Frens Jan,

I vaguely remember getting this error before but usually when projecting
NAD27 data and I don't see that in this case.

Anyrate this I think is caused by the Proj library not being able to find
the datum shift grids NAD27/83 grid translation files.  I'm really not sure
why that would even come into play here and your sample works on my proj 4.6
install on EL 4.

Anyrate to fix, I would try downloading a fresh proj copy and recompiling
your proj library from scratch and you may need to copy the
proj-datumgrid-1.4.zip in your nad/proj of your source folder before
configure make install.  I'm actually not completely clear if that is even
necessary with new installs or how all that works.

http://trac.osgeo.org/proj/


Hope that helps,
Regina


 
 

-----Original Message-----
From: postgis-users-bounces at postgis.refractions.net
[mailto:postgis-users-bounces at postgis.refractions.net] On Behalf Of Frens
Sent: Thursday, November 20, 2008 2:17 AM
To: postgis-users at postgis.refractions.net
Subject: RE: [postgis-users] Google Mercator and PostGIS under Ubuntu


Just did, but without any luck. Created fresh postgis db, but system behaves
exactly the same: faulty transform and this warning: WARNING:  transform:
-38 (failed to load NAD27-83 correction file)

Any other thoughts?

Cheers,
Frens Jan



Burgholzer,Robert wrote:
> 
> I am just guessing, but why don't you try to install a fresh PostGIS 
> enabled db in the Ubuntu machine, perhaps something in the process of 
> "restore" was not compatible, and hosed your translation.
> 
> HTH,
> r.b.
> 
> Robert W. Burgholzer
> Surface Water Modeler
> Office of Water Supply and Planning
> Virginia Department of Environmental Quality 
> rwburgholzer at deq.virginia.gov
> 804-698-4405
> Open Source Modeling Tools:
> http://sourceforge.net/projects/npsource/
> 
> -----Original Message-----
> From: postgis-users-bounces at postgis.refractions.net
> [mailto:postgis-users-bounces at postgis.refractions.net] On Behalf Of 
> Frens
> Sent: Wednesday, November 19, 2008 1:47 PM
> To: postgis-users at postgis.refractions.net
> Subject: [postgis-users] Google Mercator and PostGIS under Ubuntu
> 
> 
> Hi,
> 
> I am using PostGIS for a project quite succesfully until recently I 
> tried moving applications from my Windows based development 
> environment to a Ubuntu based test / demo environment. The postgis 
> versions etc. are exactly the same: "POSTGIS="1.3.3" 
> GEOS="3.0.0-CAPI-1.4.1" PROJ="Rel. 4.6.0, 21 Dec 2007" USE_STATS". The 
> database used on the Ubuntu machine is a restore of a backup from the 
> windows machine. (the database is an open street map db for NL).
> 
> How ever I get some weird behaviour from the translate function on the 
> Ubuntu machine. For instance if I execute the following query:
> SELECT ST_AsEWKT(
> 	ST_transform(
> 		ST_transform(
> 			GeomFromText(
> 				'POINT(5.167485 52.271499)',
> 				4326
> 			),
> 			900913
> 		),
> 		4326
> 	)
> );
> 
> on my Windows machine I get: "SRID=4326;POINT(5.16748499999999 
> 52.271499)".
> Which is what I expect. However, when I execute the exact same query 
> on my Ubuntu machine (with the same postgis / postgres / etc versions) 
> I get:
> "SRID=4326;POINT(8.10187206703149e-07 8.19541802859524e-06)". The only 
> qlue I have is that I get this warning: WARNING:  transform: -38 
> (failed to load
> NAD27-83 correction file).
> 
> So far googling didn't pay off... Anyone got some ideas?
> 
> P.S. 900913 is the SRID I use for the Google projection system, with 
> the following data in spatial_ref_sys:
> 
> srtext =
> "PROJCS["Google Mercator",GEOGCS["WGS 84",DATUM["World Geodetic System 
> 1984",SPHEROID["WGS 
> 84",6378137,0]],PRIMEM["Greenwich",0],UNIT["degree",0.0174532925199433
> ]] 
> ,PROJECTION["Mercator_2SP"],PARAMETER["standard_parallel_1",0],PARAMET
> ER 
> ["central_meridian",0],PARAMETER["false_easting",0],PARAMETER["false_n
> or thing",0],UNIT["Meter",1],EXTENSION["PROJ4","+proj=merc
> +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 
> +units=m nadgrids=@null +wktext  +no_defs"]]"
> 
> proj4text =
> "+proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 
> +y_0=0
> +k=1.0 +units=m +nadgrids=@null +wktext  +no_defs"
> --
> View this message in context:
> http://www.nabble.com/Google-Mercator-and-PostGIS-under-Ubuntu-tp20585
> 29
> 5p20585295.html
> Sent from the PostGIS - User mailing list archive at Nabble.com.
> 
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
> _______________________________________________
> postgis-users mailing list
> postgis-users at postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
> 
> 

--
View this message in context:
http://www.nabble.com/Google-Mercator-and-PostGIS-under-Ubuntu-tp20585295p20
596177.html
Sent from the PostGIS - User mailing list archive at Nabble.com.

_______________________________________________
postgis-users mailing list
postgis-users at postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users






More information about the postgis-users mailing list