From 4ef4e527014a7f2208faaa36e047ff214df66b65 Mon Sep 17 00:00:00 2001 From: niuxianhui Date: Sat, 23 May 2026 08:17:27 -0700 Subject: [PATCH] =?UTF-8?q?[fix](doc)=20remove=20LEVENSHTEIN=20doc=20page?= =?UTF-8?q?=20=E2=80=94=20function=20does=20not=20exist=20in=20Doris?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The LEVENSHTEIN page under string-functions claims a SQL function that is not implemented in apache/doris: - No `Levenshtein`/`EditDistance` entry in `fe/fe-core/src/main/java/org/apache/doris/nereids/trees/expressions/functions/scalar/` on master, branch-3.1, branch-3.0, or branch-2.1. - Calling `levenshtein(...)` errors with `Can not found function 'levenshtein'`. - The page is not referenced from any sidebar (orphan page). Remove the orphaned page from the current and 4.x trees (EN + zh). Fixes #3511 Co-Authored-By: Claude Opus 4.7 (1M context) --- .../string-functions/levenshtein.md | 37 ------------------- .../string-functions/levenshtein.md | 33 ----------------- .../string-functions/levenshtein.md | 33 ----------------- .../string-functions/levenshtein.md | 37 ------------------- 4 files changed, 140 deletions(-) delete mode 100644 docs/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md delete mode 100644 i18n/zh-CN/docusaurus-plugin-content-docs/current/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md delete mode 100644 i18n/zh-CN/docusaurus-plugin-content-docs/version-4.x/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md delete mode 100644 versioned_docs/version-4.x/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md diff --git a/docs/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md b/docs/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md deleted file mode 100644 index b23bfd29b5d44..0000000000000 --- a/docs/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md +++ /dev/null @@ -1,37 +0,0 @@ ---- -{ - "title": "LEVENSHTEIN", - "language": "en", - "description": "The LEVENSHTEIN function returns the Levenshtein edit distance between two strings." -} ---- - -## Description -The `LEVENSHTEIN` function returns the Levenshtein edit distance between two strings. -The distance is the minimum number of single-character insertions, deletions, or substitutions required to transform one string into the other. - -This function counts characters in UTF-8. - -## Syntax -```sql -LEVENSHTEIN(, ) -``` - -## Parameters -| Parameter | Description | -| -- | -- | -| `` | First string | -| `` | Second string | - -## Return Value -Returns an INT value. - -## Examples -```sql -SELECT levenshtein('kitten', 'sitting'); -- 3 -SELECT levenshtein('数据库', '数据'); -- 1 -``` - -## Notes -- Supports UTF-8 characters. -- NULL input returns NULL. diff --git a/i18n/zh-CN/docusaurus-plugin-content-docs/current/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md b/i18n/zh-CN/docusaurus-plugin-content-docs/current/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md deleted file mode 100644 index bbd1eb5d93fd1..0000000000000 --- a/i18n/zh-CN/docusaurus-plugin-content-docs/current/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md +++ /dev/null @@ -1,33 +0,0 @@ ---- -title: LEVENSHTEIN ---- - -## 描述 -`LEVENSHTEIN` 函数用于计算两个字符串之间的编辑距离。 -编辑距离是把一个字符串变成另一个字符串所需的最少单字符插入、删除或替换次数。 - -该函数按 UTF-8 字符计数。 - -## 语法 -```sql -LEVENSHTEIN(, ) -``` - -## 参数 -| 参数 | 说明 | -| -- | -- | -| `` | 第一个字符串 | -| `` | 第二个字符串 | - -## 返回值 -返回 INT。 - -## 示例 -```sql -SELECT levenshtein('kitten', 'sitting'); -- 3 -SELECT levenshtein('数据库', '数据'); -- 1 -``` - -## 说明 -- 支持 UTF-8 字符。 -- 任意参数为 NULL 时返回 NULL。 diff --git a/i18n/zh-CN/docusaurus-plugin-content-docs/version-4.x/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md b/i18n/zh-CN/docusaurus-plugin-content-docs/version-4.x/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md deleted file mode 100644 index bbd1eb5d93fd1..0000000000000 --- a/i18n/zh-CN/docusaurus-plugin-content-docs/version-4.x/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md +++ /dev/null @@ -1,33 +0,0 @@ ---- -title: LEVENSHTEIN ---- - -## 描述 -`LEVENSHTEIN` 函数用于计算两个字符串之间的编辑距离。 -编辑距离是把一个字符串变成另一个字符串所需的最少单字符插入、删除或替换次数。 - -该函数按 UTF-8 字符计数。 - -## 语法 -```sql -LEVENSHTEIN(, ) -``` - -## 参数 -| 参数 | 说明 | -| -- | -- | -| `` | 第一个字符串 | -| `` | 第二个字符串 | - -## 返回值 -返回 INT。 - -## 示例 -```sql -SELECT levenshtein('kitten', 'sitting'); -- 3 -SELECT levenshtein('数据库', '数据'); -- 1 -``` - -## 说明 -- 支持 UTF-8 字符。 -- 任意参数为 NULL 时返回 NULL。 diff --git a/versioned_docs/version-4.x/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md b/versioned_docs/version-4.x/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md deleted file mode 100644 index b23bfd29b5d44..0000000000000 --- a/versioned_docs/version-4.x/sql-manual/sql-functions/scalar-functions/string-functions/levenshtein.md +++ /dev/null @@ -1,37 +0,0 @@ ---- -{ - "title": "LEVENSHTEIN", - "language": "en", - "description": "The LEVENSHTEIN function returns the Levenshtein edit distance between two strings." -} ---- - -## Description -The `LEVENSHTEIN` function returns the Levenshtein edit distance between two strings. -The distance is the minimum number of single-character insertions, deletions, or substitutions required to transform one string into the other. - -This function counts characters in UTF-8. - -## Syntax -```sql -LEVENSHTEIN(, ) -``` - -## Parameters -| Parameter | Description | -| -- | -- | -| `` | First string | -| `` | Second string | - -## Return Value -Returns an INT value. - -## Examples -```sql -SELECT levenshtein('kitten', 'sitting'); -- 3 -SELECT levenshtein('数据库', '数据'); -- 1 -``` - -## Notes -- Supports UTF-8 characters. -- NULL input returns NULL.