pingcap / tidb

TiDB - the open-source, cloud-native, distributed SQL database designed for modern applications.
https://pingcap.com
Apache License 2.0
37.2k stars 5.84k forks source link

Failed in executing ch and report error “exceeding the allowed memory limit for a single SQL query” #57051

Open jolynejo opened 4 hours ago

jolynejo commented 4 hours ago

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

1、run ch q21 on v8.4.0 tidb

2. What did you expect to see? (Required)

q21 select results

3. What did you see instead (Required)

[2024/10/31 17:51:27.206 +08:00] [ERROR] [ch.go:320] ["end query"] [qno=q21] ["sql comment"=] ["consume time"=4s] ["result count"=0] [error="Error 8175 (HY000): Your query has been cancelled due to exceeding the allowed memory limit for a single SQL query. Please try narrowing your query scope or increase the tidb_mem_quota_query limit and try again.[conn=104862650]"]

4. What is your TiDB version? (Required)

| Release Version: v8.4.0 Edition: Enterprise Git Commit Hash: 35470384fc75a2878a6617e91e6ba55b72faf77b Git Branch: HEAD UTC Build Time: 2024-10-31 03:55:33 GoVersion: go1.23.2 Race Enabled: false Check Table Before Drop: false Store: tikv Enterprise Extension Commit Hash: cb58c31ad9364cc770b250a4702c8d7b75f98b1a |

jolynejo commented 3 hours ago

/type bug /severity major /assign elsa0520 /label affects-8.4