pingcap/tidb

show memory_table regions return unexpected result

Open

#50,808 opened on Jan 30, 2024

View on GitHub
 (0 comments) (0 reactions) (1 assignee)Go (6,186 forks)batch import
help wantedseverity/minorsig/sql-infratype/bug

Repository metrics

Stars
 (40,090 stars)
PR merge metrics
 (Avg merge 14d 4h) (369 merged PRs in 30d)

Description

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

show table information_schema.tables regions;

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

empty result. since information_schema.tables is a memory table, it shouldn't have any data in any tikv region.

3. What did you see instead (Required)

+-----------+--------------------+----------+-----------+-----------------+-------+------------+---------------+------------+----------------------+------------------+------------------------+------------------+
| REGION_ID | START_KEY          | END_KEY  | LEADER_ID | LEADER_STORE_ID | PEERS | SCATTERING | WRITTEN_BYTES | READ_BYTES | APPROXIMATE_SIZE(MB) | APPROXIMATE_KEYS | SCHEDULING_CONSTRAINTS | SCHEDULING_STATE |
+-----------+--------------------+----------+-----------+-----------------+-------+------------+---------------+------------+----------------------+------------------+------------------------+------------------+
| 52        | t_281474976710654_ | 78000000 | 53        | 1               | 53    | 0          | 0             | 1872000    | 1                    | 477              |                        |                  |
+-----------+--------------------+----------+-----------+-----------------+-------+------------+---------------+------------+----------------------+------------------+------------------------+------------------+

4. What is your TiDB version? (Required)

+-----------------------------------------------------------+
| tidb_version()                                            |
+-----------------------------------------------------------+
| Release Version: v8.0.0-alpha-143-g7087f70                |
| Edition: Community                                        |
| Git Commit Hash: 7087f702e18f811c98d5a276eace7bb69292c6aa |
| Git Branch: HEAD                                          |
| UTC Build Time: 2024-01-30 03:53:25                       |
| GoVersion: go1.21.4                                       |
| Race Enabled: false                                       |
| Check Table Before Drop: false                            |
| Store: tikv                                               |
+-----------------------------------------------------------+

Contributor guide