Example: TO_MGRS - Analytics Database - Teradata Vantage

Geospatial Data Types

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
ft:locale
en-US
ft:lastEdition
2023-08-30
dita:mapPath
qgk1628112272483.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
ghz1472251264557
lifecycle
latest
Product Category
Teradata Vantage™

This example converts Geodetic coordinates in the “WGS 84” spatial reference system to MGRS.

SELECT TO_MGRS(
  new ST_GEOMETRY('ST_POINT', 30, 45), 
  (select SRTEXT from sysspatial.spatial_ref_sys where srid = 1619), 
  5);

Returns:

TO_MGRS(NEW ST_GEOMETRY('ST_POINT', 30, 45),<Scalar Subquery>,5 )
-----------------------------------------------------------------
36TTQ6355387329