eldenmoon commented on code in PR #2685:
URL: https://github.com/apache/doris-website/pull/2685#discussion_r2247047574


##########
i18n/zh-CN/docusaurus-plugin-content-docs/current/sql-manual/sql-functions/scalar-functions/array-functions/arrays-overlap.md:
##########
@@ -5,52 +5,152 @@
 }
 ---
 
-## 描述
+## 功能
 
-判断 left 和 right 数组中是否包含公共元素
+`ARRAYS_OVERLAP` 用于判断两个数组是否存在至少一个**相同的非空元素**,如果存在返回 `true`,否则返回 `false`。
 
 ## 语法
 
-```sql
-ARRAYS_OVERLAP(<left>, <right>)
+```SQL
+ARRAYS_OVERLAP(arr1, arr2)
 ```
 
 ## 参数
 
-| 参数 | 说明 |
-|--|--|
-| `<left>` | 待判断的数组 |
-| `<right>` | 待判断的数组 |
+- `arr1`:第一个数组,类型为 `ARRAY<T>`。
+
+- `arr2`:第二个数组,类型为 `ARRAY<T>`。
+
+    - 两个数组的元素类型 `T` 必须一致或可以相互隐式转换。
+    - 两个数组的元素类型 `T` 不能是半结构化类型。
+    - 参数可以是构造的常量,也可以是变量。
 
 ## 返回值
 
-如果 left 和 right 具有任何非 null 的共同元素,则返回 true。
-如果没有非 null 的共同元素且任一数组包含 null,则返回 null。
-如果没有非 null 的共同元素,且 left 和 right 都不包含 null,则返回 false。
+- 返回 `BOOLEAN` 类型:
 
-## 举例
+    - 如果两个数组有交集,返回 `true`;
 
-```
-select arrays_overlap([1, 2, 3], [1, null]);
-+--------------------------------------+
-| arrays_overlap([1, 2, 3], [1, null]) |
-+--------------------------------------+
-|                                    1 |
-+--------------------------------------+
-
-
-select arrays_overlap([2, 3], [1, null]);
-+-----------------------------------+
-| arrays_overlap([2, 3], [1, null]) |
-+-----------------------------------+
-|                              NULL |
-+-----------------------------------+
-
-select arrays_overlap([2, 3], [1]);
-+-----------------------------+
-+-----------------------------+
-| arrays_overlap([2, 3], [1]) |
-+-----------------------------+
-|                           0 |
-+-----------------------------+
-```
+    - 如果没有交集,返回 `false`;
+
+    - 如果任一参数为 `NULL`,则返回 `NULL` (见示例)。
+
+## 使用说明
+
+1. **比较方式使用元素的等值判断(= 运算符)**。
+2. **如果没有相同的非空元素,当数组的元素中包含 `NULL` 时,返回值是 `NULL`**(具体见示例)。

Review Comment:
   例子是 null和null overlap的



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to