Mike,<div>Yes, I mean <meta http-equiv="content-type" content="text/html; charset=utf-8">georeferenced (sorry for my English). I made a cast to text and converted to postgis geometry, but I couldn't use <meta http-equiv="content-type" content="text/html; charset=utf-8">ST_SetSRID.</div>
<div>I would like to tranfer a polygon to correct position. I have a Polygon "BOX(743295.3125 7182512.5,744414.75 7183817.5)" and I like to transfer it to "BOX(-54.515022277832 -25.4530487060547,-54.5029907226562 -25.4447135925293)".</div>
<div>I tried ST_Affine but I don't know the correct parameters, I tried ST_Scale but I had the same problem. My idea was transform and set srid.</div><div><br><br><div class="gmail_quote">On Tue, Oct 26, 2010 at 11:44 PM, Mike Toews <span dir="ltr"><<a href="mailto:mwtoews@gmail.com">mwtoews@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi Wagner,<br>
<br>
I'm not sure what you mean by "geo" and "non-geo" .. you mean<br>
georeferenced, like longitude/latitude?<br>
<br>
For points, you can keep thing binary and just use ST_MakePoint(x,y).<br>
And to assign a coordinate system, use it with ST_SetSRID:<br>
<br>
SELECT ST_SetSRID(ST_MakePoint(p[0], p[1]), 4326)<br>
from (<br>
  select point '(-123.112793, 49.246293)' as p<br>
) as foo;<br>
<br>
I'm not sure how to do similar binary conversions for path and<br>
polygon, or other types. You might have to cast to text, and wrangle<br>
it into some form of WKT, then pass it to ST_SetSRID(text, integer) to<br>
make a geometry object for PostGIS.<br>
<br>
-Mike<br>
<div><div></div><div class="h5"><br>
<br>
On 26 October 2010 18:17, Wagner Santos <<a href="mailto:wagner.desenv@gmail.com">wagner.desenv@gmail.com</a>> wrote:<br>
> I created a Postgis Geometry from Postgres Polygon converting them  from<br>
> string and using linefromtext to create a geometry but this information<br>
> isn't geo.<br>
> I have non geo points and I want to convert to my correct position and set<br>
> SRID, for example P(70 72) to P(-54 -25), how can I do this?<br>
> Thanks!<br>
><br>
> On Tue, Oct 26, 2010 at 1:18 PM, Wagner Santos <<a href="mailto:wagner.desenv@gmail.com">wagner.desenv@gmail.com</a>><br>
> wrote:<br>
>><br>
>> Hello,<br>
>> I'm new with postgis and I have a legacy database with Postgres Polygon, I<br>
>> want to convert this to a Postgis Geometry. Is there a way?<br>
>> I try to do with replace string and linefromtext with sucess, but I think<br>
>> doesn't better solution because I can't set a valid SRID.<br>
>> Thanks!<br>
><br>
</div></div>> _______________________________________________<br>
> postgis-users mailing list<br>
> <a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a><br>
> <a href="http://postgis.refractions.net/mailman/listinfo/postgis-users" target="_blank">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><br>
><br>
><br>
_______________________________________________<br>
postgis-users mailing list<br>
<a href="mailto:postgis-users@postgis.refractions.net">postgis-users@postgis.refractions.net</a><br>
<a href="http://postgis.refractions.net/mailman/listinfo/postgis-users" target="_blank">http://postgis.refractions.net/mailman/listinfo/postgis-users</a><br>
</blockquote></div><br></div>