<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px"><div dir="ltr" id="yui_3_16_0_1_1422934971250_10617"><span id="yui_3_16_0_1_1422934971250_10801">Hi.</span></div><div id="yui_3_16_0_1_1422934971250_10802" dir="ltr"><span id="yui_3_16_0_1_1422934971250_10801"><br></span></div><div id="yui_3_16_0_1_1422934971250_10803" dir="ltr"><span id="yui_3_16_0_1_1422934971250_10801">Try something like:<br></span></div><div id="yui_3_16_0_1_1422934971250_10796" dir="ltr"><span id="yui_3_16_0_1_1422934971250_10800"><br></span></div><div id="yui_3_16_0_1_1422934971250_10798" dir="ltr"><span id="yui_3_16_0_1_1422934971250_10797">update <table> set <geometry column> = ST_SetSRID(ST_MakePoint(Longitude, Latitude),4326);</span></div><div id="yui_3_16_0_1_1422934971250_10799"><br></div><div id="yui_3_16_0_1_1422934971250_10804" dir="ltr">Essentially create a point geometry from your numeric values, with the ST_MakePoint() function, the inform Postgis it is a standard lat/long CS (EPSG:4326 - which you should have specified when you created the column), & update the table with these values for each row. Make sure you use your table & column names....</div><div id="yui_3_16_0_1_1422934971250_10838" dir="ltr"><br></div><div id="yui_3_16_0_1_1422934971250_10839" dir="ltr">What mapping/GIS program are you using?<br></div><div id="yui_3_16_0_1_1422934971250_10806" dir="ltr"><br></div><div id="yui_3_16_0_1_1422934971250_10811" dir="ltr">Cheers,</div><div id="yui_3_16_0_1_1422934971250_10807" dir="ltr"><br></div><div id="yui_3_16_0_1_1422934971250_10808" dir="ltr"> Brent Wood<br></div><div id="yui_3_16_0_1_1422934971250_10809"><br> </div><div id="yui_3_16_0_1_1422934971250_10676" style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div id="yui_3_16_0_1_1422934971250_10675" style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;"> <div id="yui_3_16_0_1_1422934971250_10674" dir="ltr"> <hr id="yui_3_16_0_1_1422934971250_10691" size="1"> <font id="yui_3_16_0_1_1422934971250_10673" face="Arial" size="2"> <b><span style="font-weight:bold;">From:</span></b> KhunSanAung <khunsanaung.gis@gmail.com><br> <b><span style="font-weight: bold;">To:</span></b> postgis-users@lists.osgeo.org <br> <b><span style="font-weight: bold;">Sent:</span></b> Tuesday, February 3, 2015 5:11 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> [postgis-users] Convert from Lat/Long point to postGIS geometry<br> </font> </div> <div id="yui_3_16_0_1_1422934971250_10810" class="y_msg_container"><br><div id="yiv0179715380"><div id="yui_3_16_0_1_1422934971250_10841" dir="ltr"><div id="yui_3_16_0_1_1422934971250_10840" class="yiv0179715380gmail_default" style="color:rgb(0,0,255);">Hi All,</div><div id="yui_3_16_0_1_1422934971250_10842" class="yiv0179715380gmail_default" style="color:rgb(0,0,255);"><br></div><div id="yui_3_16_0_1_1422934971250_10843" class="yiv0179715380gmail_default" style="color:rgb(0,0,255);">I have one table (Town info) in postgres without Geometry field.</div><div id="yui_3_16_0_1_1422934971250_10844" class="yiv0179715380gmail_default" style="color:rgb(0,0,255);">I have Latitude and Longitude information for those points data separately (collecting & filling).<br></div><div id="yui_3_16_0_1_1422934971250_10845" class="yiv0179715380gmail_default" style="color:rgb(0,0,255);"><br></div><div id="yui_3_16_0_1_1422934971250_10846" class="yiv0179715380gmail_default" style="color:rgb(0,0,255);">I created the postGIS extension and add the Geometry field in the above postgres table.</div><div id="yui_3_16_0_1_1422934971250_10847" class="yiv0179715380gmail_default" style="color:rgb(0,0,255);">Now, I'd like to add the location information into the postGIS geometry field so that I can immediately view those points on the map. </div><div id="yui_3_16_0_1_1422934971250_10848" class="yiv0179715380gmail_default" style="color:rgb(0,0,255);"><br></div><div class="yiv0179715380gmail_default" style="color:rgb(0,0,255);">How can I convert the Latitude/Longitude value into postGIS geometry value?</div><div class="yiv0179715380gmail_default" style="color:rgb(0,0,255);"><br></div><div class="yiv0179715380gmail_default" style="color:rgb(0,0,255);">Thank you very much in advance.</div><div class="yiv0179715380gmail_default" style="color:rgb(0,0,255);"><br></div>-- <br><div class="yiv0179715380gmail_signature"><div dir="ltr"><span style="color:rgb(0,0,153);">Have a nice day!</span><br>--<br><div style="line-height:115%;"><b><span style="font-size:9pt;line-height:115%;color:rgb(127,127,127);" lang="EN-GB">Mr. Khun San Aung</span></b></div><u><span style="font-size:9pt;line-height:115%;color:blue;" lang="EN-GB"><a rel="nofollow" target="_blank" href="http://geoportal.icimod.org/"></a></span></u><u><span style="font-size:9pt;line-height:115%;color:rgb(127,127,127);" lang="EN-GB"></span></u></div></div>
</div></div><br>_______________________________________________<br>postgis-users mailing list<br><a ymailto="mailto:postgis-users@lists.osgeo.org" href="mailto:postgis-users@lists.osgeo.org">postgis-users@lists.osgeo.org</a><br><a href="http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users" target="_blank">http://lists.osgeo.org/cgi-bin/mailman/listinfo/postgis-users</a><br><br></div> </div> </div> </div></body></html>