Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add explanation to approx_count_distinct #10627

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

moyun
Copy link
Contributor

@moyun moyun commented Jul 22, 2022

First-time contributors' checklist

What is changed, added or deleted? (Required)

add explanation to approx_count_distinct

Which TiDB version(s) do your changes apply to? (Required)

Tips for choosing the affected version(s):

By default, CHOOSE MASTER ONLY so your changes will be applied to the next TiDB major or minor releases. If your PR involves a product feature behavior change or a compatibility change, CHOOSE THE AFFECTED RELEASE BRANCH(ES) AND MASTER.

For details, see tips for choosing the affected versions (in Chinese).

  • master (the latest development version)
  • v6.2 (TiDB 6.2 versions)
  • v6.1 (TiDB 6.1 versions)
  • v5.4 (TiDB 5.4 versions)
  • v5.3 (TiDB 5.3 versions)
  • v5.2 (TiDB 5.2 versions)
  • v5.1 (TiDB 5.1 versions)
  • v5.0 (TiDB 5.0 versions)

What is the related PR or file link(s)?

  • This PR is translated from:
  • Other reference link(s):

Do your changes match any of the following descriptions?

  • Delete files
  • Change aliases
  • Need modification after applied to another branch
  • Might cause conflicts after applied to another branch

add explanation to approx_count_distinct
@ti-chi-bot
Copy link
Member

[REVIEW NOTIFICATION]

This pull request has not been approved.

To complete the pull request process, please ask the reviewers in the list to review by filling /cc @reviewer in the comment.
After your PR has acquired the required number of LGTMs, you can assign this pull request to the committer in the list by filling /assign @committer in the comment to help you merge this pull request.

The full list of commands accepted by this bot can be found here.

Reviewer can indicate their review by submitting an approval review.
Reviewer can cancel approval by submitting a request changes review.

@ti-chi-bot ti-chi-bot requested a review from TomShawn July 22, 2022 03:25
@ti-chi-bot ti-chi-bot added missing-translation-status This PR does not have translation status info. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. labels Jul 22, 2022
@shichun-0415 shichun-0415 added translation/doing This PR’s assignee is translating this PR. type/bugfix This PR fixes a bug. area/bigdata Indicates that the Issue or PR belongs to the area of TiFlash, TiSpark, and OLAP. needs-cherry-pick-release-6.1 Should cherry pick this PR to release-6.1 branch. and removed missing-translation-status This PR does not have translation status info. labels Jul 22, 2022
@shichun-0415 shichun-0415 self-assigned this Jul 22, 2022
@shichun-0415 shichun-0415 requested review from shichun-0415 and solotzg and removed request for TomShawn July 22, 2022 03:47
@@ -35,7 +35,8 @@ TiFlash 支持部分算子的下推,支持的算子如下:
* 日期函数:`date_format, timestampdiff, from_unixtime, unix_timestamp(int), unix_timestamp(decimal), str_to_date(date), str_to_date(datetime), datediff, year, month, day, extract(datetime), date, hour, microsecond, minute, second, sysdate, date_add, date_sub, adddate, subdate, quarter, dayname, dayofmonth, dayofweek, dayofyear, last_day, monthname, to_seconds, to_days, from_days, weekofyear`
* JSON 函数:`json_length`
* 转换函数:`cast(int as double), cast(int as decimal), cast(int as string), cast(int as time), cast(double as int), cast(double as decimal), cast(double as string), cast(double as time), cast(string as int), cast(string as double), cast(string as decimal), cast(string as time), cast(decimal as int), cast(decimal as string), cast(decimal as time), cast(time as int), cast(time as decimal), cast(time as string), cast(time as real)`
* 聚合函数:`min, max, sum, count, avg, approx_count_distinct, group_concat`
* 聚合函数:`min, max, sum, count, avg, group_concat`
* 聚合函数(近似算法):`approx_count_distinct` (功能同 `count`,计算速度有数量级的提升,但可能带来 1% ~ 5% 的误差。适合对精度要求不高的大量数据做快速统计。)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

功能上是 COUNT(DISTINCT) 近似结果

@ti-chi-bot
Copy link

ti-chi-bot bot commented Apr 23, 2023

PR needs rebase.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@ti-chi-bot ti-chi-bot bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Apr 23, 2023
@qiancai
Copy link
Collaborator

qiancai commented Jul 7, 2023

Removed the needs-cherry-pick-release-6.6 label because the v6.6 docs have been archived at https://docs-archive.pingcap.com/zh/tidb/v6.6 and will no longer receive new updates.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/bigdata Indicates that the Issue or PR belongs to the area of TiFlash, TiSpark, and OLAP. needs-cherry-pick-release-6.1 Should cherry pick this PR to release-6.1 branch. needs-cherry-pick-release-6.5 Should cherry pick this PR to release-6.5 branch. needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. translation/doing This PR’s assignee is translating this PR. type/bugfix This PR fixes a bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants