diff --git a/docs/user-guide/manage-data/data-index.md b/docs/user-guide/manage-data/data-index.md index 4615799c7..748a86dee 100644 --- a/docs/user-guide/manage-data/data-index.md +++ b/docs/user-guide/manage-data/data-index.md @@ -79,6 +79,21 @@ CREATE TABLE logs ( ); ``` + +Fulltext index supports options by `WITH`: +* `analyzer`: Sets the language analyzer for the fulltext index. Supported values are `English` and `Chinese`. Default to `English`. +* `case_sensitive`: Determines whether the fulltext index is case-sensitive. Supported values are `true` and `false`. Default to `false`. + +For example: + +```sql +CREATE TABLE logs ( + message STRING FULLTEXT WITH(analyzer='Chinese', case_sensitive='true'), + `level` STRING PRIMARY KEY, + `timestamp` TIMESTAMP TIME INDEX, +); +``` + Fulltext index usually comes with following drawbacks: - Higher storage overhead compared to regular indexes due to storing word tokens and positions diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/user-guide/manage-data/data-index.md b/i18n/zh/docusaurus-plugin-content-docs/current/user-guide/manage-data/data-index.md index 0e7663508..dd748dcb2 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/current/user-guide/manage-data/data-index.md +++ b/i18n/zh/docusaurus-plugin-content-docs/current/user-guide/manage-data/data-index.md @@ -79,6 +79,20 @@ CREATE TABLE logs ( ); ``` +全文索引通过 `WITH` 支持以下选项: +* `analyzer`:设置全文索引的语言分析器。支持的值包括 `English`(英语)和 `Chinese`(中文)。默认值为 `English`。 +* `case_sensitive`:决定全文索引是否区分大小写。支持的值为 `true`(是)和 `false`(否)。默认值为 `false`。 + +示例: + +```sql +CREATE TABLE logs ( + message STRING FULLTEXT WITH(analyzer='Chinese', case_sensitive='true'), + `level` STRING PRIMARY KEY, + `timestamp` TIMESTAMP TIME INDEX, +); +``` + 使用全文索引时需要注意以下限制: - 存储开销较大,因需要保存词条和位置信息 diff --git a/i18n/zh/docusaurus-plugin-content-docs/version-0.11/user-guide/manage-data/data-index.md b/i18n/zh/docusaurus-plugin-content-docs/version-0.11/user-guide/manage-data/data-index.md index 0e7663508..dd748dcb2 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/version-0.11/user-guide/manage-data/data-index.md +++ b/i18n/zh/docusaurus-plugin-content-docs/version-0.11/user-guide/manage-data/data-index.md @@ -79,6 +79,20 @@ CREATE TABLE logs ( ); ``` +全文索引通过 `WITH` 支持以下选项: +* `analyzer`:设置全文索引的语言分析器。支持的值包括 `English`(英语)和 `Chinese`(中文)。默认值为 `English`。 +* `case_sensitive`:决定全文索引是否区分大小写。支持的值为 `true`(是)和 `false`(否)。默认值为 `false`。 + +示例: + +```sql +CREATE TABLE logs ( + message STRING FULLTEXT WITH(analyzer='Chinese', case_sensitive='true'), + `level` STRING PRIMARY KEY, + `timestamp` TIMESTAMP TIME INDEX, +); +``` + 使用全文索引时需要注意以下限制: - 存储开销较大,因需要保存词条和位置信息 diff --git a/versioned_docs/version-0.11/user-guide/manage-data/data-index.md b/versioned_docs/version-0.11/user-guide/manage-data/data-index.md index 4615799c7..8a1f0d5dc 100644 --- a/versioned_docs/version-0.11/user-guide/manage-data/data-index.md +++ b/versioned_docs/version-0.11/user-guide/manage-data/data-index.md @@ -79,6 +79,20 @@ CREATE TABLE logs ( ); ``` +Fulltext index supports options by `WITH`: +* `analyzer`: Sets the language analyzer for the fulltext index. Supported values are `English` and `Chinese`. Default to `English`. +* `case_sensitive`: Determines whether the fulltext index is case-sensitive. Supported values are `true` and `false`. Default to `false`. + +For example: + +```sql +CREATE TABLE logs ( + message STRING FULLTEXT WITH(analyzer='Chinese', case_sensitive='true'), + `level` STRING PRIMARY KEY, + `timestamp` TIMESTAMP TIME INDEX, +); +``` + Fulltext index usually comes with following drawbacks: - Higher storage overhead compared to regular indexes due to storing word tokens and positions