[postgis-users] Working with multilinestring data - figuringout coordinates
lr at pcorp.us
Fri Sep 11 13:16:21 PDT 2009
typo correction to Paul's note.
select st_astext(st_transform(the_geom,4326)) As wktgeom4326 from yourtable
I should add it depends how you plan to use this. The ST_AsText is mostly
for viewing the text representation or to feed to systems that only accept
So normally you would just do
SELECT st_transform(the_geom,4326) As the_geom from yourtable;
Varies depending on which front end you are feeding to.
You may also want to consider not using 4326 and keeping it in 2269 if you
are going to be using this for measurement. WGS84 is not a useful
transform measurement (at least not yet anyway).
Hope that doesn't confuse you more,
From: postgis-users-bounces at postgis.refractions.net
[mailto:postgis-users-bounces at postgis.refractions.net] On Behalf Of Paul
Sent: Friday, September 11, 2009 4:01 PM
To: PostGIS Users Discussion
Subject: Re: [postgis-users] Working with multilinestring data - figuringout
Given those coordinates and your proj4 definition, it looks like the data is
in SRS 2269, which this test seems to confirm:
If your data does not have an SRID already set, set it to 2269, thusly:
update yourtable set yourgeomcolumn = st_setsrid(yourgeomcolumn,2269);
Now you can pull out other projections (like 4326 (lonlat)) using the
select st_astext(st_transform(the_geom)) from yourtable limit 1;
On Fri, Sep 11, 2009 at 12:34 PM, Mac Martine <martine at adobe.com> wrote:
> I'm a total newbie with this stuff so bare with me. I have a shape
> files that I got into Postgres. Now I'm pulling it out and it's giving
> me MULTILINESTRINGS with numbers that look like:
> 7509930.12510756 776667.642310877,7509924.12502675 776694.329928875
> Now, I get the feeling those are correct, but that I need to convert
> them to Longitude and Latitude, and that's where I'm stuck.
> I'm pretty sure it's SRID 4326 but I can't find any info on doing
> conversions from here. Maybe I'm wrong. I also found this info which
> may be of help.
> +proj=lcc +lat_1=44.33333333333334 +lat_2=46 +lat_0=43.66666666666666
> +lon_0=-120.5 +x_0=2500000 +y_0=0 +ellps=GRS80 +to_meter=0.3048
> I'd really appreciate some guidance. I've googled all kinds of things
> and am not figuring it out.
> postgis-users mailing list
> postgis-users at postgis.refractions.net
postgis-users mailing list
postgis-users at postgis.refractions.net
More information about the postgis-users