Skip to content

the results of tikv and tiflash are different  #37258

@ChenPeng2013

Description

@ChenPeng2013

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

use test;
source [test.txt](https://github.com/pingcap/tidb/files/9391075/test.txt)
alter table PK_HP9202 set tiflash replica 1;
select sleep(5);
select /*+ read_from_storage(tikv[PK_HP9202]) */ count(*) from PK_HP9202 where col1  or col3 between -8596086079896239827 and -8596086079896239827 and col2 is not null;
select /*+ read_from_storage(tiflash[PK_HP9202]) */ count(*) from PK_HP9202 where col1  or col3 between -8596086079896239827 and -8596086079896239827 and col2 is not null;

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

3. What did you see instead (Required)

MySQL [test]> select /*+ read_from_storage(tikv[PK_HP9202]) */ count(*) from PK_HP9202 where col1  or col3 between -8596086079896239827 and -8596086079896239827 and col2 is not null;
+----------+
| count(*) |
+----------+
|      102 |
+----------+
1 row in set (0.01 sec)

MySQL [test]> select /*+ read_from_storage(tiflash[PK_HP9202]) */ count(*) from PK_HP9202 where col1  or col3 between -8596086079896239827 and -8596086079896239827 and col2 is not null;
+----------+
| count(*) |
+----------+
|       70 |
+----------+
1 row in set (0.03 sec)

4. What is your TiDB version? (Required)

Release Version: v6.3.0-alpha
Edition: Community
Git Commit Hash: 8b5b724d8a932239303a1d0ba547323eb0e5161b
Git Branch: heads/refs/tags/v6.3.0-alpha
UTC Build Time: 2022-08-19 14:31:05
GoVersion: go1.18.5
Race Enabled: false
TiKV Min Version: 6.2.0-alpha
Check Table Before Drop: false
Store: tikv

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions