你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn。
geo_s2cell_to_central_point()
计算表示 S2 单元格中心的地理空间坐标。
语法
geo_s2cell_to_central_point(
s2cell)
详细了解语法约定。
参数
名称 | 类型 | 必需 | 说明 |
---|---|---|---|
s2cell | string |
✔️ | 由 geo_point_to_s2cell() 计算得出的 S2 单元格令牌值。 S2 单元格令牌的最大字符串长度为 16 个字符。 |
返回
地理空间坐标值采用 GeoJSON 格式,属于动态数据类型。 如果 S2 单元格令牌无效,则查询会生成 null 结果。
注意
GeoJSON 格式先指定经度,再指定纬度。
示例
print point = geo_s2cell_to_central_point("1234567")
| extend coordinates = point.coordinates
| extend longitude = coordinates[0], latitude = coordinates[1]
输出
point | 坐标 | longitude | latitude |
---|---|---|---|
{ "type":"Point", "coordinates": [ 9.86830731850408, 27.468392925827604 ] } |
[ 9.86830731850408, 27.468392925827604 ] |
9.86830731850408 | 27.4683929258276 |
下面的示例由于 S2 单元格令牌输入无效而返回 null 结果。
print point = geo_s2cell_to_central_point("a")
输出
point |
---|
反馈
https://aka.ms/ContentUserFeedback。
即将发布:在整个 2024 年,我们将逐步淘汰作为内容反馈机制的“GitHub 问题”,并将其取代为新的反馈系统。 有关详细信息,请参阅:提交和查看相关反馈