Try http://www.spatialreference.org/ref/esri/3997/postgis/  The site is down
for me at the moment but should have the goods.

-Francis

On 3 May 2010 17:50, Mehmet Erkek <mer...@reidin.com> wrote:

>  Thank you for the fast answer!
>
>
> Hmm. It looks I don’t have srid 3997 in the DB.
>
>
>
>
>
> =# select srid, srtext, proj4text from spatial_ref_sys where srid=3997;
>
>  srid | srtext | proj4text
>
> ------+--------+-----------
>
> (0 rows)
>
>
>
> select srid, srtext, proj4text from spatial_ref_sys where  srtext like
> '%Dubai%';
>
>  srid | srtext | proj4text
>
> ------+--------+-----------
>
> (0 rows)
>
>
>
>
>
> Could this be related to my postgis installation?
>
>
>
> I don’t see this srid in spatial_ref_sys.sql which came with postgis
> installation either.
>
>
>
> Any idea how I can fix this?
>
>
>
>
>
> -------------------------------------------------------------------
>
> *Mehmet ERKEK***
>
> www.REIDIN.com <http://www.reidin.com/>
>
>
>
> *From:* postgis-users-boun...@postgis.refractions.net [mailto:
> postgis-users-boun...@postgis.refractions.net] *On Behalf Of *Francis
> Markham
> *Sent:* Monday, May 03, 2010 11:09 AM
> *To:* PostGIS Users Discussion
> *Subject:* Re: [postgis-users] Converting UTM to lat/lon using Postgis
>
>
>
> Hi Mehmet,
>
> When you imported the shapefile, the SRID you are meant to specify is the
> SRID of the data, not the SRID you want.  Since the data is in Dubai Local
> TM, the SRID is 3997.  To get the transformation you want, try the
> following:
>
> select   ST_AsText( ST_Transform(centroid(ST_SetSRID(the_geom,
> 3997)),4326)) from ult.test2 limit 5;
>
> Hope that helps,
>
> -Francis
>
> On 3 May 2010 17:03, Mehmet Erkek <mer...@reidin.com> wrote:
>
>
>
> Hi All,
>
>
>
> I havea a shape file which I imported it to a table called ‘test2’ (using
>  SRID=4326).  I want to get centroids of geometries in lat/lon.
>
>
>
> Here is what I run:
>
>
>
> select   ST_AsText( ST_Transform(centroid(the_geom),4326)) from ult.test2
> limit 5;
>
>
>
> and what I get:
>
>
>
> POINT(496597.996430787 2774798.21242881)
>
> POINT(496332.629887436 2793339.61534586)
>
> POINT(496302.627327975 2793317.82477318)
>
> POINT(496305.255261594 2793353.29646291)
>
> POINT(496241.538851096 2774826.65593589)
>
>
>
>
>
> So far all is fine except coordinates which are not  latitude/longitude
>
>
>
> *My question is : How can I convert/get these coordinates in lat/lon?*
>
>
>
>
>
> This what I have in my prj file:
>
>
>
> PROJCS["Dubai Local Transverse Mercator
> (DLTM)",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Transverse_Mercator"],PARAMETER["False_Easting",500000.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",55.33333333333334],PARAMETER["Scale_Factor",1.0],PARAMETER["Latitude_Of_Origin",0.0],UNIT["Meter",1.0]]
>
>
>
>
>
> And this is my postgis version: POSTGIS="1.3.6" GEOS="2.2.3-CAPI-1.1.1"
> PROJ="Rel. 4.7.1, 23 September 2009" USE_STATS
>
>
>
> I appreciate any help. Thank you.
>
>
>
>
>
> -------------------------------------------------------------------
>
> *Mehmet ERKEK*
>
> www.REIDIN.com <http://www.reidin.com/>
>
>
>
>
> This message is for the designated recipient only and may contain
> privileged, proprietary, or otherwise private information. If you have
> received it in error, please notify the sender immediately and delete the
> original. Any other use of the email by you is prohibited. Please Consider
> the Environment Before Printing This Email
>
>
> _______________________________________________
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
>
>
> This message is for the designated recipient only and may contain
> privileged, proprietary, or otherwise private information. If you have
> received it in error, please notify the sender immediately and delete the
> original. Any other use of the email by you is prohibited. Please Consider
> the Environment Before Printing This Email
>
> _______________________________________________
> postgis-users mailing list
> postgis-users@postgis.refractions.net
> http://postgis.refractions.net/mailman/listinfo/postgis-users
>
>
_______________________________________________
postgis-users mailing list
postgis-users@postgis.refractions.net
http://postgis.refractions.net/mailman/listinfo/postgis-users

Reply via email to