Please answer these questions before submitting your issue. Thanks!
<!-- a step by step guide for reproducing the bug. -->
([email protected]:4000)[test]
([email protected]:4000)[test]show create table t;
+-------+------------------------------------------------------------------------------------------------------------+
| Table | Create Table |
+-------+------------------------------------------------------------------------------------------------------------+
| t | CREATE TABLE `t` (
`id` int(11) DEFAULT NULL
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_bin |
+-------+------------------------------------------------------------------------------------------------------------+
1 row in set (0.05 sec)
([email protected]:4000)[test]select * from t lock in share mode;
ERROR 1105 (HY000): Can't find column test.t._tidb_rowid in schema Column: [test.t.id] Unique key: []
([email protected]:4000)[test]
select * from t lock in share mode;
Empty set (0.00 sec)
ERROR 1105 (HY000): Can't find column test.t._tidb_rowid in schema Column: [test.t.id] Unique key: []
v4.0.3 and v4.0.4
/label sig/execution
Can't reproduce on master branch.
tidb(localhost:4000) > create table t (a int);
Query OK, 0 rows affected (0.14 sec)
tidb(localhost:4000) > select * from t lock in share mode;
ERROR 1235 (42000): function LOCK IN SHARE MODE has only noop implementation in tidb now, use tidb_enable_noop_functions to enable these functions
tidb(localhost:4000) > set @@tidb_enable_noop_functions = 1;
Query OK, 0 rows affected (0.00 sec)
tidb(localhost:4000) > select * from t lock in share mode;
Empty set (0.01 sec)
But it can be reproduced on release-4.0 branch.
tidb(localhost:4000) > select * from t lock in share mode;
ERROR 1105 (HY000): Can't find column test.t._tidb_rowid in schema Column: [test.t.a] Unique key: []
Maybe we should cherry-pick
https://github.com/pingcap/tidb/pull/19506
https://github.com/pingcap/tidb/pull/19630
to release-4.0 branch.
@cfzjywxk @nullnotnil PTAL.
/assign @cfzjywxk
/assign @nullnotnil
OK, I'll take a look.
I am going to cherry pick only SELECT .. LOCK IN SHARE MODE. I am concerned about cherry picking CALC_FOUND_ROWS to the release branch.
@nullnotnil A friendly ping
@nullnotnil A friendly ping
PR https://github.com/pingcap/tidb/pull/21005 created and merged. There has not been a cherry pick for https://github.com/pingcap/tidb/pull/19630 yet, so I will leave this issue open.
Maybe we should cherry-pick
19506
19630
to release-4.0 branch.
@cfzjywxk @nullnotnil PTAL.
I checked that master dose not have this problem because master has another bug which may cover this one..
closed by #21126
Note: Make Sure that 'component', and 'severity' labels are added
Example for how to fill out the template: https://github.com/pingcap/tidb/issues/20100
Most helpful comment
I am going to cherry pick only
SELECT .. LOCK IN SHARE MODE. I am concerned about cherry pickingCALC_FOUND_ROWSto the release branch.