From 5100a75adcae31ed49053d0cb1f9cc43bed5048f Mon Sep 17 00:00:00 2001 From: guo-shaoge Date: Fri, 16 Apr 2021 19:22:23 +0800 Subject: [PATCH] fix cases Signed-off-by: guo-shaoge --- executor/executor_test.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/executor/executor_test.go b/executor/executor_test.go index daee412f9679e..2c5d8f3caadec 100644 --- a/executor/executor_test.go +++ b/executor/executor_test.go @@ -6892,12 +6892,12 @@ func (s *testSuiteP2) TestApplyCache(c *C) { tk.MustExec("insert into t values (1),(1),(1),(1),(1),(1),(1),(1),(1);") tk.MustExec("analyze table t;") result := tk.MustQuery("explain analyze SELECT count(1) FROM (SELECT (SELECT min(a) FROM t as t2 WHERE t2.a > t1.a) AS a from t as t1) t;") - c.Assert(result.Rows()[1][0], Equals, "└─Apply_39") + c.Assert(result.Rows()[2][0], Equals, " └─Apply_41") var ( ind int flag bool ) - value := (result.Rows()[1][5]).(string) + value := (result.Rows()[2][5]).(string) for ind = 0; ind < len(value)-5; ind++ { if value[ind:ind+5] == "cache" { flag = true @@ -6912,9 +6912,9 @@ func (s *testSuiteP2) TestApplyCache(c *C) { tk.MustExec("insert into t values (1),(2),(3),(4),(5),(6),(7),(8),(9);") tk.MustExec("analyze table t;") result = tk.MustQuery("explain analyze SELECT count(1) FROM (SELECT (SELECT min(a) FROM t as t2 WHERE t2.a > t1.a) AS a from t as t1) t;") - c.Assert(result.Rows()[1][0], Equals, "└─Apply_39") + c.Assert(result.Rows()[2][0], Equals, " └─Apply_41") flag = false - value = (result.Rows()[1][5]).(string) + value = (result.Rows()[2][5]).(string) for ind = 0; ind < len(value)-5; ind++ { if value[ind:ind+5] == "cache" { flag = true