MI_Length - spectrum_spatial - Latest

Spectrum Spatial Guide

Product type
Software
Portfolio
Locate
Product family
Spectrumâ„¢ software
Product
Spectrumâ„¢ software > Spatial > Spectrum Spatial
Version
Latest
ft:locale
en-US
Product name
Spectrum Technology Platform
ft:title
Spectrum Spatial Guide
Copyright
2025
First publish date
2007
ft:lastEdition
2025-03-07
ft:lastPublication
2025-03-07T10:28:48.112000

Description

Returns the geographic length of a line or polyline geometry object.

Syntax

MI_Length ( geometry, unit, calculationType )

Arguments

geometry is an expression which returns a geometry,

unit is a linear unit specification, and

calculationType is a string that indicates whether to perform a Spherical or Cartesian calculation. There is no default.

Example

Returns the length of a highway from the CanadaHighway table.

select highway from CanadaHighway where MI_Length(Obj,'mi','Spherical') <= 50

Remarks

The value returned is a double and represents a value in the units specified by the units argument. MI_Length is applicable only to geometries of type Curve, LineString, and MultiCurve. Any other type of input geometry results in a value of zero.

Valid values for unit are the following distance units:

Value Description
mi miles
km kilometers
in inches
ft feet
yd yards
mm millimeters
cm centimeters
m meters
survey ft US Survey feet
nmi nautical miles
twip twips
pt points
pica picas
degree degrees
li links
ch chains
rd rods