diff --git a/expression/expr_to_pb_test.go b/expression/expr_to_pb_test.go index cf949394e7077..aba6aa3475cca 100644 --- a/expression/expr_to_pb_test.go +++ b/expression/expr_to_pb_test.go @@ -1386,11 +1386,6 @@ func TestExprPushDownToTiKV(t *testing.T) { retType: types.NewFieldType(mysql.TypeString), args: []Expression{stringColumn, stringColumn, intColumn}, }, - { - functionName: ast.Instr, - retType: types.NewFieldType(mysql.TypeInt24), - args: []Expression{stringColumn, stringColumn}, - }, { functionName: ast.Quote, retType: types.NewFieldType(mysql.TypeString), diff --git a/expression/expression.go b/expression/expression.go index fe56ff5520883..656447931a8f0 100644 --- a/expression/expression.go +++ b/expression/expression.go @@ -970,7 +970,7 @@ func scalarExprSupportedByTiKV(sf *ScalarFunction) bool { // string functions. ast.Bin, ast.Unhex, ast.Locate, ast.Ord, ast.Lpad, ast.Rpad, ast.Trim, ast.FromBase64, ast.ToBase64, ast.Upper, ast.Lower, ast.InsertFunc, - ast.MakeSet, ast.SubstringIndex, ast.Instr, ast.Quote, ast.Oct, + ast.MakeSet, ast.SubstringIndex /* ast.Instr */, ast.Quote, ast.Oct, ast.FindInSet, ast.Repeat, ast.Length, ast.BitLength, ast.Concat, ast.ConcatWS, ast.Replace, ast.ASCII, ast.Hex, ast.Reverse, ast.LTrim, ast.RTrim, ast.Strcmp, ast.Space, ast.Elt, ast.Field, diff --git a/planner/core/integration_test.go b/planner/core/integration_test.go index 49661c3119ab6..c28014215a4f8 100644 --- a/planner/core/integration_test.go +++ b/planner/core/integration_test.go @@ -2912,10 +2912,6 @@ func TestScalarFunctionPushDown(t *testing.T) { tk.MustQuery("explain analyze select /*+read_from_storage(tikv[t])*/ * from t where substring_index(c,c,1)"). CheckAt([]int{0, 3, 6}, rows) - rows[1][2] = "instr(test.t.c, test.t.c)" - tk.MustQuery("explain analyze select /*+read_from_storage(tikv[t])*/ * from t where instr(c,c)"). - CheckAt([]int{0, 3, 6}, rows) - rows[1][2] = "quote(test.t.c)" tk.MustQuery("explain analyze select /*+read_from_storage(tikv[t])*/ * from t where quote(c)"). CheckAt([]int{0, 3, 6}, rows)