MGRS coordinates

From IMSMA Wiki
Revision as of 16:16, 6 February 2014 by Alnaucler (talk | contribs) (Created page with "SELECT geopoint.userenteredcoord, concat( upper(left(geopoint.userenteredcoord, locate('|', geopoint.userenteredcoord) -1)),right(geopoint.userenteredcoord,7)) FROM geopoint ...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

SELECT geopoint.userenteredcoord, concat( upper(left(geopoint.userenteredcoord, locate('|', geopoint.userenteredcoord) -1)),right(geopoint.userenteredcoord,7))

FROM geopoint

WHERE geopoint.coordrefsys = 'MGRS' AND

binary left(geopoint.userenteredcoord, locate('|', geopoint.userenteredcoord) -1) <> upper(left(geopoint.userenteredcoord, locate('|', geopoint.userenteredcoord) -1))

ORDER BY length(geopoint.userenteredcoord)