From 4b04e7c14971a6891573fc833470a7d6eff4e779 Mon Sep 17 00:00:00 2001 From: evenyag Date: Sat, 3 May 2025 11:58:16 +0800 Subject: [PATCH] docs: tql analyze also supports verbose --- docs/reference/sql/tql.md | 10 ++++++++-- .../current/reference/sql/tql.md | 8 +++++++- .../version-0.14/reference/sql/tql.md | 8 +++++++- versioned_docs/version-0.14/reference/sql/tql.md | 8 +++++++- 4 files changed, 29 insertions(+), 5 deletions(-) diff --git a/docs/reference/sql/tql.md b/docs/reference/sql/tql.md index cc609c32d..664dd1b65 100644 --- a/docs/reference/sql/tql.md +++ b/docs/reference/sql/tql.md @@ -12,7 +12,7 @@ The `TQL` keyword executes TQL language in SQL. The TQL is Time-Series Query Lan ### Syntax ```sql -TQL [EVAL | EVALUATE] (start, end, step) expr +TQL [EVAL | EVALUATE] (start, end, step) expr ``` The `start`, `end` and `step` are the query parameters just like [Prometheus Query API](https://prometheus.io/docs/prometheus/latest/querying/api/): @@ -96,7 +96,7 @@ The result should be like the following: TQL also supports `ANALYZE` keyword to analyze the given PromQL query's execution. The syntax is as follows: ``` -TQL ANALYZE (start, end, step) expr; +TQL ANALYZE [VERBOSE] (start, end, step) expr; ``` For example: @@ -121,3 +121,9 @@ will get a result like | +-------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ``` + +Using `TQL ANALYZE VERBOSE` will get a verbose result of the execution. + +``` +TQL ANALYZE VERBOSE (0, 10, '5s') test; +``` diff --git a/i18n/zh/docusaurus-plugin-content-docs/current/reference/sql/tql.md b/i18n/zh/docusaurus-plugin-content-docs/current/reference/sql/tql.md index e7d6caa29..01aeb9d61 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/current/reference/sql/tql.md +++ b/i18n/zh/docusaurus-plugin-content-docs/current/reference/sql/tql.md @@ -12,7 +12,7 @@ description: 介绍了 `TQL` 关键字及其在 GreptimeDB 中的用法,包括 ### Syntax ```sql -TQL [EVAL | EVALUATE] (start, end, step) expr +TQL [EVAL | EVALUATE] (start, end, step) expr ``` `start`, `end` 和 `step` 是查询参数,就像 [Prometheus Query API](https://prometheus.io/docs/prometheus/latest/querying/api/) 一样: @@ -121,3 +121,9 @@ TQL ANALYZE (0, 10, '5s') test; | +-------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ``` + +使用 `TQL ANALYZE VERBOSE` 可以拿到查询执行时更详细的信息. + +``` +TQL ANALYZE VERBOSE (0, 10, '5s') test; +``` diff --git a/i18n/zh/docusaurus-plugin-content-docs/version-0.14/reference/sql/tql.md b/i18n/zh/docusaurus-plugin-content-docs/version-0.14/reference/sql/tql.md index e7d6caa29..01aeb9d61 100644 --- a/i18n/zh/docusaurus-plugin-content-docs/version-0.14/reference/sql/tql.md +++ b/i18n/zh/docusaurus-plugin-content-docs/version-0.14/reference/sql/tql.md @@ -12,7 +12,7 @@ description: 介绍了 `TQL` 关键字及其在 GreptimeDB 中的用法,包括 ### Syntax ```sql -TQL [EVAL | EVALUATE] (start, end, step) expr +TQL [EVAL | EVALUATE] (start, end, step) expr ``` `start`, `end` 和 `step` 是查询参数,就像 [Prometheus Query API](https://prometheus.io/docs/prometheus/latest/querying/api/) 一样: @@ -121,3 +121,9 @@ TQL ANALYZE (0, 10, '5s') test; | +-------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ``` + +使用 `TQL ANALYZE VERBOSE` 可以拿到查询执行时更详细的信息. + +``` +TQL ANALYZE VERBOSE (0, 10, '5s') test; +``` diff --git a/versioned_docs/version-0.14/reference/sql/tql.md b/versioned_docs/version-0.14/reference/sql/tql.md index cc609c32d..d4d83b15d 100644 --- a/versioned_docs/version-0.14/reference/sql/tql.md +++ b/versioned_docs/version-0.14/reference/sql/tql.md @@ -12,7 +12,7 @@ The `TQL` keyword executes TQL language in SQL. The TQL is Time-Series Query Lan ### Syntax ```sql -TQL [EVAL | EVALUATE] (start, end, step) expr +TQL [EVAL | EVALUATE] (start, end, step) expr ``` The `start`, `end` and `step` are the query parameters just like [Prometheus Query API](https://prometheus.io/docs/prometheus/latest/querying/api/): @@ -121,3 +121,9 @@ will get a result like | +-------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ``` + +Using `TQL ANALYZE VERBOSE` will get a verbose result of the execution. + +``` +TQL ANALYZE VERBOSE (0, 10, '5s') test; +```