<->(point,point)
两者之间的距离
当前查看 PostgreSQL 18.6。
说明
两者之间的距离
- 左操作数
- point
- 右操作数
- point
- 返回类型
- float8
- 实现函数
- point_distance(point,point)
- 操作符种类
- Binary
- 可用于哈希连接
- 否
- 可用于归并连接
- 否
用法
<->(point,point) → float8目录记录解读
目录 pg_operator 存储关于操作符的信息。详见 CREATE OPERATOR 和 第 36.14 节 。
声明的操作符家族成员关系
| 索引访问方法 | 操作符家族 | 策略 | 用途 | 排序家族 |
|---|---|---|---|---|
| GiST | point_ops | 15 | 排序 | float_ops |
| SP-GiST | quad_point_ops | 15 | 排序 | float_ops |
| SP-GiST | kd_point_ops | 15 | 排序 | float_ops |
相关条目
文档与源码
- Matching PostgreSQL source archive
- PostgreSQL 18 English manual: catalog-pg-operator.html
- PostgreSQL 18 English manual: catalog-pg-amop.html
来源构建
- 版本
- 18.6
- 构建
- https://ftp.postgresql.org/pub/source/v18.6/postgresql-18.6.tar.bz2
- 来源指纹
555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f
版本比较
PostgreSQL 11 → 12: 属性变化。
以下差异保留原始字段名与英文源描述。
--- PostgreSQL 11
+++ PostgreSQL 12
@@ -4,6 +4,26 @@
"family": "point_ops",
"left_type": "point",
"method": "gist",
+ "operator": "<->(point,point)",
+ "purpose": "ordering",
+ "right_type": "point",
+ "sort_family": "float_ops",
+ "strategy": "15"
+ },
+ {
+ "family": "kd_point_ops",
+ "left_type": "point",
+ "method": "spgist",
+ "operator": "<->(point,point)",
+ "purpose": "ordering",
+ "right_type": "point",
+ "sort_family": "float_ops",
+ "strategy": "15"
+ },
+ {
+ "family": "quad_point_ops",
+ "left_type": "point",
+ "method": "spgist",
"operator": "<->(point,point)",
"purpose": "ordering",
"right_type": "point",
比较已记录的接口与属性,排除来源指纹和构建元数据。某个样本中没有记录,不能据此判断实际引入或移除的版本。
相关条目
导出 JSON · 返回运算符 · 收录范围为 PostgreSQL 10 至 20;最早采样版本不一定是实际引入版本。