[postgis-users] Area and scale completely wrong

Barend Köbben kobben at itc.nl
Mon Nov 14 02:44:51 PST 2005


In ArcGIS/ArcView  the original projection of the data can be different from the projection of the View (or data frame in ArcGIS). EG. you data could be in decimal degrees, 0,0 being the convergence of the equator with the Greenwich meridian, while it could be projected to meters in UTM where 0,0 could be quite another place on earth. In ArcGIS you can see the projections of the data layer and the data frame by looking at the propoerties of these two things (right clicking them). In ArcView I think (don't have it here) you sholdl be able to see that data too of respectively the layer and the View. The easiest wai in PostGIS is just lloking at the numbers of the coordinates: if you 
 select AsText(geom) from your table and see coordinates like 2.93883558758 10.227323263, you're looking at decimal degrees latitude-longitude, if you see coords like 2125353.32 12263535.33 it's meter coordinates in some cartesian system...


___________________________

Barend Köbben
International Institute for Geo-information 
Sciences and Earth Observation (ITC) 
PO Box 6, 7500AA Enschede (The Netherlands)
ph: +31 (0)53 4874253; fax: +31 (0)53 4874335


 

> -----Original Message-----
> From: postgis-users-bounces at postgis.refractions.net 
> [mailto:postgis-users-bounces at postgis.refractions.net] On 
> Behalf Of Johan Wehtje
> Sent: 14 November 2005 11:34
> To: PostGIS Users Discussion
> Subject: Re: [postgis-users] Area and scale completely wrong
> 
> How would I check this.
> 
> 
> On 11/14/05, strk at refractions.net <strk at refractions.net > wrote:
> 
> 	None of the measurement functions in postgis take 
> projection into
> 	account. Computations are purely cartesian. Can it be that the 
> 	input (shapefile) is really in decimal degrees and it 
> is transformed
> 	(reprojected) to GDA94/MGA84 during ARC load ?
> 	
> 	--strk;
> 	
> 	On Mon, Nov 14, 2005 at 08:25:54PM +1100, Johan Wehtje wrote:
> 	> isvalid returns true, envelope gives results that 
> make no sense outside of 
> 	> the world of Lilliput.
> 	>
> 	> I had some of the same maps but with MGA 84 zone 56 
> datum, and they have
> 	> loaded no problem, I therefore think that the 
> definition for the GDA94
> 	> spatial refernces must be out of whack, because the 
> shape files have no 
> 	> problem when loaded in arc view in either GDA 94 or MGA 84.
> 	>
> 	> The GDA 94 shapes have attached xml files, and the 
> pojection string in these
> 	> does look the same as the proj4 text in the Spatial 
> Refsys table, so I don't 
> 	> know what is going wrong.
> 	>
> 	> Cheers
> 	> (and thanks your help)
> 	> Johan Wehtje
> 	>
> 	> On 11/14/05, strk at refractions.net < 
> strk at refractions.net <mailto:strk at refractions.net> > wrote:
> 	> >
> 	> > Does the area computation give acceptable value for 
> the geometry's
> 	> > envelope ? [ select area(envelope(the_geom)) ] ?
> 	> > Is the geometry valid ? [ select isvalid(the_geom) ] ? 
> 	> >
> 	> > --strk;
> 	> >
> 	> > On Mon, Nov 14, 2005 at 07:50:10PM +1100, Johan 
> Wehtje wrote:
> 	> > > I am using Postgis 1.0.4 on Win XP with Postgresql 8.1.
> 	> > >
> 	> > > I had some Shape files that have Land Parcels , 
> they use GDA94 Zone 56 ( 
> 	> > > srid 28356) , and I used shp2pgsql to load them 
> into my DB.
> 	> > >
> 	> > > But when I an area calculation I get results that 
> are completely wrong ,
> 	> > and
> 	> > > when i add a Postgis layer using QGIS the scale 
> would have me beleive 
> 	> > that
> 	> > > the entire shire (which about 80 km accross) is 
> about 2 cm.
> 	> > >
> 	> > > I have tried this about twenty times, on 2 
> different machines - and the
> 	> > > results are the same. i have verified the 
> original shape files in 
> 	> > Arcview,
> 	> > > and when they are laoded the scale and area are 
> all what they should be.
> 	> > >
> 	> > > What am I doing wrong?
> 	> > >
> 	> > > Johan Wehtje 
> 	> >
> 	> > > _______________________________________________
> 	> > > postgis-users mailing list
> 	> > > postgis-users at postgis.refractions.net 
> 	> > > 
> http://postgis.refractions.net/mailman/listinfo/postgis-users
> 	> >
> 	> >
> 	> > --
> 	> >
> 	> > /"\ ASCII Ribbon Campaign 
> 	> > \ / Respect for open standards
> 	> > X No HTML/RTF in email
> 	> > / \ No M$ Word docs in email
> 	> >
> 	> > _______________________________________________
> 	> > 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
> 	
> 	
> 	--
> 	
> 	/"\    ASCII Ribbon Campaign
> 	\ /    Respect for open standards 
> 	  X     No HTML/RTF in email
> 	/ \    No M$ Word docs in email
> 	
> 	_______________________________________________
> 	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