[mapguide-users] How to best consume Map Data
Hans Milling
hm at geograf.dk
Wed Sep 7 02:39:53 PDT 2016
I know that oracle as a SDO_UTIL.FROM_WKTGEOMETRY you can use in an insert or
update statement.
You need to convert your points to WKT (Well Known Text).
If you have the following data points that should turn into a polygon:
x, y
30, 10
40, 40
20, 40
10, 20
30, 10
TO write this in WKT format (Note that spaces devide each x and y and that
comma devide each coordinate pair):
POLYGON ((30 10, 40 40, 20 40, 10 20, 30 10))
You can do an:
insert into mypolygons (attr1, attr2, geometrycolumn) Values(1, 'Name',
SDO_UTIL.FROM_WKTGEOMETRY('POLYGON ((30 10, 40 40, 20 40, 10 20, 30 10))');
The table has to have a geometry column of type SDO_GEOMETRY to store the
geometry data and for MapGuide to be able to display these. The geometry
column you specify an SRID that tells the database what coordinate system
the coordinates are in. Two system are widely used. Either
Latitude/Longitude in WGS84 that has SPID/EPSG 4326 or you are using your
local EUREF89 UTM zone coordinates (A lot of different ID's are used, you
can find them with a simple Google search).
Best regards
Hans Milling...
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/How-to-best-consume-Map-Data-tp5284418p5284464.html
Sent from the MapGuide Users mailing list archive at Nabble.com.
More information about the mapguide-users
mailing list