pingcap / tiflash

The analytical engine for TiDB and TiDB Cloud. Try free: https://tidbcloud.com/free-trial
https://docs.pingcap.com/tidb/stable/tiflash-overview
Apache License 2.0
937 stars 409 forks source link

Support SQL mode of `ERROR_FOR_DIVISION_BY_ZERO` #9107

Open gengliqi opened 1 month ago

gengliqi commented 1 month ago

What problem does this PR solve?

Issue Number: ref https://github.com/pingcap/tiflash/issues/9106

Problem Summary:

What is changed and how it works?

  1. make div and mod function support ERROR_FOR_DIVISION_BY_ZERO
  2. report warning if in read-only sql or non-strict sql mode

TODO: Error message and error code are still different from TiDB and TiKV. img_v3_02bd_3431d323-27a7-4a09-83a8-4fb2343a04ag

Support SQL mode of `ERROR_FOR_DIVISION_BY_ZERO`

Check List

Tests

Side effects

Documentation

Release note

None
ti-chi-bot[bot] commented 1 month ago

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: Once this PR has been reviewed and has the lgtm label, please ask for approval from gengliqi, ensuring that each of them provides their approval before proceeding. For more information see the Code Review Process.

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

Needs approval from an approver in each of these files: - **[OWNERS](https://github.com/pingcap/tiflash/blob/master/OWNERS)** Approvers can indicate their approval by writing `/approve` in a comment Approvers can cancel approval by writing `/approve cancel` in a comment
ti-chi-bot[bot] commented 3 days ago

PR needs rebase.

Instructions for interacting with me using PR comments are available [here](https://git.k8s.io/community/contributors/guide/pull-requests.md). If you have questions or suggestions related to my behavior, please file an issue against the [kubernetes/test-infra](https://github.com/kubernetes/test-infra/issues/new?title=Prow%20issue:) repository.