Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

planner: add tests for partition range boundaries for LT/GT #24574

Merged
merged 9 commits into from
May 20, 2021
46 changes: 46 additions & 0 deletions executor/partition_table_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -1829,3 +1829,49 @@ PARTITION BY RANGE (a) (
s.testData.GetTestCases(c, &input, &output)
s.verifyPartitionResult(tk, input, output)
}

func (s *testSuiteWithData) TestRangePartitionBoundariesLtM(c *C) {
tk := testkit.NewTestKit(c, s.store)

tk.MustExec("set @@tidb_partition_prune_mode = 'dynamic'")
tk.MustExec("create database TestRangePartitionBoundariesLtM")
defer tk.MustExec("drop database TestRangePartitionBoundariesLtM")
tk.MustExec("use TestRangePartitionBoundariesLtM")
tk.MustExec("drop table if exists t")
tk.MustExec(`CREATE TABLE t
(a INT, b varchar(255))
PARTITION BY RANGE (a) (
PARTITION p0 VALUES LESS THAN (1000000),
PARTITION p1 VALUES LESS THAN (2000000),
PARTITION p2 VALUES LESS THAN (3000000))`)

var input []string
var output []testOutput
s.testData.GetTestCases(c, &input, &output)
s.verifyPartitionResult(tk, input, output)
}

func (s *testSuiteWithData) TestRangePartitionBoundariesLtS(c *C) {
tk := testkit.NewTestKit(c, s.store)

tk.MustExec("set @@tidb_partition_prune_mode = 'dynamic'")
tk.MustExec("create database TestRangePartitionBoundariesLtS")
defer tk.MustExec("drop database TestRangePartitionBoundariesLtS")
tk.MustExec("use TestRangePartitionBoundariesLtS")
tk.MustExec("drop table if exists t")
tk.MustExec(`CREATE TABLE t
(a INT, b varchar(255))
PARTITION BY RANGE (a) (
PARTITION p0 VALUES LESS THAN (1),
PARTITION p1 VALUES LESS THAN (2),
PARTITION p2 VALUES LESS THAN (3),
PARTITION p3 VALUES LESS THAN (4),
PARTITION p4 VALUES LESS THAN (5),
PARTITION p5 VALUES LESS THAN (6),
PARTITION p6 VALUES LESS THAN (7))`)

var input []string
var output []testOutput
s.testData.GetTestCases(c, &input, &output)
s.verifyPartitionResult(tk, input, output)
}
335 changes: 335 additions & 0 deletions executor/testdata/executor_suite_in.json
Original file line number Diff line number Diff line change
Expand Up @@ -273,5 +273,340 @@
"SELECT * FROM t WHERE a BETWEEN 2 AND 7",
"SELECT * FROM t WHERE a BETWEEN 7 AND 4"
]
},
{
"name": "TestRangePartitionBoundariesLtM",
"cases": [
"INSERT INTO t VALUES (999998, '999998 Filler ...'), (999999, '999999 Filler ...'), (1000000, '1000000 Filler ...'), (1000001, '1000001 Filler ...'), (1000002, '1000002 Filler ...')",
"INSERT INTO t VALUES (1999998, '1999998 Filler ...'), (1999999, '1999999 Filler ...'), (2000000, '2000000 Filler ...'), (2000001, '2000001 Filler ...'), (2000002, '2000002 Filler ...')",
"INSERT INTO t VALUES (2999998, '2999998 Filler ...'), (2999999, '2999999 Filler ...')",
"INSERT INTO t VALUES (-2147483648, 'MIN_INT filler...'), (0, '0 Filler...')",
"ANALYZE TABLE t",
"SELECT * FROM t WHERE a < -2147483648",
"SELECT * FROM t WHERE a > -2147483648",
"SELECT * FROM t WHERE a <= -2147483648",
"SELECT * FROM t WHERE a >= -2147483648",
"SELECT * FROM t WHERE a < 0",
"SELECT * FROM t WHERE a > 0",
"SELECT * FROM t WHERE a <= 0",
"SELECT * FROM t WHERE a >= 0",
"SELECT * FROM t WHERE a < 999998",
"SELECT * FROM t WHERE a > 999998",
"SELECT * FROM t WHERE a <= 999998",
"SELECT * FROM t WHERE a >= 999998",
"SELECT * FROM t WHERE a < 999999",
"SELECT * FROM t WHERE a > 999999",
"SELECT * FROM t WHERE a <= 999999",
"SELECT * FROM t WHERE a >= 999999",
"SELECT * FROM t WHERE a < 1000000",
"SELECT * FROM t WHERE a > 1000000",
"SELECT * FROM t WHERE a <= 1000000",
"SELECT * FROM t WHERE a >= 1000000",
"SELECT * FROM t WHERE a < 1000001",
"SELECT * FROM t WHERE a > 1000001",
"SELECT * FROM t WHERE a <= 1000001",
"SELECT * FROM t WHERE a >= 1000001",
"SELECT * FROM t WHERE a < 1000002",
"SELECT * FROM t WHERE a > 1000002",
"SELECT * FROM t WHERE a <= 1000002",
"SELECT * FROM t WHERE a >= 1000002",
"SELECT * FROM t WHERE a < 3000000",
"SELECT * FROM t WHERE a > 3000000",
"SELECT * FROM t WHERE a <= 3000000",
"SELECT * FROM t WHERE a >= 3000000",
"SELECT * FROM t WHERE a < 3000001",
"SELECT * FROM t WHERE a > 3000001",
"SELECT * FROM t WHERE a <= 3000001",
"SELECT * FROM t WHERE a >= 3000001",
"SELECT * FROM t WHERE a < 999997",
"SELECT * FROM t WHERE a > 999997",
"SELECT * FROM t WHERE a <= 999997",
"SELECT * FROM t WHERE a >= 999997",
"SELECT * FROM t WHERE a >= 999997 AND a <= 999999",
"SELECT * FROM t WHERE a > 999997 AND a <= 999999",
"SELECT * FROM t WHERE a > 999997 AND a < 999999",
"SELECT * FROM t WHERE a > 999997 AND a <= 999999",
"SELECT * FROM t WHERE a < 999998",
"SELECT * FROM t WHERE a > 999998",
"SELECT * FROM t WHERE a <= 999998",
"SELECT * FROM t WHERE a >= 999998",
"SELECT * FROM t WHERE a >= 999998 AND a <= 1000000",
"SELECT * FROM t WHERE a > 999998 AND a <= 1000000",
"SELECT * FROM t WHERE a > 999998 AND a < 1000000",
"SELECT * FROM t WHERE a > 999998 AND a <= 1000000",
"SELECT * FROM t WHERE a < 999999",
"SELECT * FROM t WHERE a > 999999",
"SELECT * FROM t WHERE a <= 999999",
"SELECT * FROM t WHERE a >= 999999",
"SELECT * FROM t WHERE a >= 999999 AND a <= 1000001",
"SELECT * FROM t WHERE a > 999999 AND a <= 1000001",
"SELECT * FROM t WHERE a > 999999 AND a < 1000001",
"SELECT * FROM t WHERE a > 999999 AND a <= 1000001",
"SELECT * FROM t WHERE a < 1000000",
"SELECT * FROM t WHERE a > 1000000",
"SELECT * FROM t WHERE a <= 1000000",
"SELECT * FROM t WHERE a >= 1000000",
"SELECT * FROM t WHERE a >= 1000000 AND a <= 1000002",
"SELECT * FROM t WHERE a > 1000000 AND a <= 1000002",
"SELECT * FROM t WHERE a > 1000000 AND a < 1000002",
"SELECT * FROM t WHERE a > 1000000 AND a <= 1000002",
"SELECT * FROM t WHERE a < 1999997",
"SELECT * FROM t WHERE a > 1999997",
"SELECT * FROM t WHERE a <= 1999997",
"SELECT * FROM t WHERE a >= 1999997",
"SELECT * FROM t WHERE a >= 1999997 AND a <= 1999999",
"SELECT * FROM t WHERE a > 1999997 AND a <= 1999999",
"SELECT * FROM t WHERE a > 1999997 AND a < 1999999",
"SELECT * FROM t WHERE a > 1999997 AND a <= 1999999",
"SELECT * FROM t WHERE a < 1999998",
"SELECT * FROM t WHERE a > 1999998",
"SELECT * FROM t WHERE a <= 1999998",
"SELECT * FROM t WHERE a >= 1999998",
"SELECT * FROM t WHERE a >= 1999998 AND a <= 2000000",
"SELECT * FROM t WHERE a > 1999998 AND a <= 2000000",
"SELECT * FROM t WHERE a > 1999998 AND a < 2000000",
"SELECT * FROM t WHERE a > 1999998 AND a <= 2000000",
"SELECT * FROM t WHERE a < 1999999",
"SELECT * FROM t WHERE a > 1999999",
"SELECT * FROM t WHERE a <= 1999999",
"SELECT * FROM t WHERE a >= 1999999",
"SELECT * FROM t WHERE a >= 1999999 AND a <= 2000001",
"SELECT * FROM t WHERE a > 1999999 AND a <= 2000001",
"SELECT * FROM t WHERE a > 1999999 AND a < 2000001",
"SELECT * FROM t WHERE a > 1999999 AND a <= 2000001",
"SELECT * FROM t WHERE a < 2000000",
"SELECT * FROM t WHERE a > 2000000",
"SELECT * FROM t WHERE a <= 2000000",
"SELECT * FROM t WHERE a >= 2000000",
"SELECT * FROM t WHERE a >= 2000000 AND a <= 2000002",
"SELECT * FROM t WHERE a > 2000000 AND a <= 2000002",
"SELECT * FROM t WHERE a > 2000000 AND a < 2000002",
"SELECT * FROM t WHERE a > 2000000 AND a <= 2000002",
"SELECT * FROM t WHERE a < 2999997",
"SELECT * FROM t WHERE a > 2999997",
"SELECT * FROM t WHERE a <= 2999997",
"SELECT * FROM t WHERE a >= 2999997",
"SELECT * FROM t WHERE a >= 2999997 AND a <= 2999999",
"SELECT * FROM t WHERE a > 2999997 AND a <= 2999999",
"SELECT * FROM t WHERE a > 2999997 AND a < 2999999",
"SELECT * FROM t WHERE a > 2999997 AND a <= 2999999",
"SELECT * FROM t WHERE a < 2999998",
"SELECT * FROM t WHERE a > 2999998",
"SELECT * FROM t WHERE a <= 2999998",
"SELECT * FROM t WHERE a >= 2999998",
"SELECT * FROM t WHERE a >= 2999998 AND a <= 3000000",
"SELECT * FROM t WHERE a > 2999998 AND a <= 3000000",
"SELECT * FROM t WHERE a > 2999998 AND a < 3000000",
"SELECT * FROM t WHERE a > 2999998 AND a <= 3000000",
"SELECT * FROM t WHERE a < 2999999",
"SELECT * FROM t WHERE a > 2999999",
"SELECT * FROM t WHERE a <= 2999999",
"SELECT * FROM t WHERE a >= 2999999",
"SELECT * FROM t WHERE a >= 2999999 AND a <= 3000001",
"SELECT * FROM t WHERE a > 2999999 AND a <= 3000001",
"SELECT * FROM t WHERE a > 2999999 AND a < 3000001",
"SELECT * FROM t WHERE a > 2999999 AND a <= 3000001",
"SELECT * FROM t WHERE a < 3000000",
"SELECT * FROM t WHERE a > 3000000",
"SELECT * FROM t WHERE a <= 3000000",
"SELECT * FROM t WHERE a >= 3000000",
"SELECT * FROM t WHERE a >= 3000000 AND a <= 3000002",
"SELECT * FROM t WHERE a > 3000000 AND a <= 3000002",
"SELECT * FROM t WHERE a > 3000000 AND a < 3000002",
"SELECT * FROM t WHERE a > 3000000 AND a <= 3000002"
]
},
{
"name": "TestRangePartitionBoundariesLtS",
"cases": [
"INSERT INTO t VALUES (0, '0 Filler...')",
"INSERT INTO t VALUES (1, '1 Filler...')",
"INSERT INTO t VALUES (2, '2 Filler...')",
"INSERT INTO t VALUES (3, '3 Filler...')",
"INSERT INTO t VALUES (4, '4 Filler...')",
"INSERT INTO t VALUES (5, '5 Filler...')",
"INSERT INTO t VALUES (6, '6 Filler...')",
"ANALYZE TABLE t",
"SELECT * FROM t WHERE a < -1",
"SELECT * FROM t WHERE a > -1",
"SELECT * FROM t WHERE a <= -1",
"SELECT * FROM t WHERE a >= -1",
"SELECT * FROM t WHERE a < 2 OR a > -1",
"SELECT * FROM t WHERE a > 2 AND a < -1",
"SELECT * FROM t WHERE NOT (a < 2 OR a > -1)",
"SELECT * FROM t WHERE NOT (a > 2 AND a < -1)",
"SELECT * FROM t WHERE a < 2 OR a >= -1",
"SELECT * FROM t WHERE a >= 2 AND a < -1",
"SELECT * FROM t WHERE NOT (a < 2 OR a >= -1)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a < -1)",
"SELECT * FROM t WHERE a <= 2 OR a > -1",
"SELECT * FROM t WHERE a > 2 AND a <= -1",
"SELECT * FROM t WHERE NOT (a <= 2 OR a > -1)",
"SELECT * FROM t WHERE NOT (a > 2 AND a <= -1)",
"SELECT * FROM t WHERE a <= 2 OR a >= -1",
"SELECT * FROM t WHERE a >= 2 AND a <= -1",
"SELECT * FROM t WHERE NOT (a <= 2 OR a >= -1)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a <= -1)",
"SELECT * FROM t WHERE a < 0",
"SELECT * FROM t WHERE a > 0",
"SELECT * FROM t WHERE a <= 0",
"SELECT * FROM t WHERE a >= 0",
"SELECT * FROM t WHERE a < 2 OR a > 0",
"SELECT * FROM t WHERE a > 2 AND a < 0",
"SELECT * FROM t WHERE NOT (a < 2 OR a > 0)",
"SELECT * FROM t WHERE NOT (a > 2 AND a < 0)",
"SELECT * FROM t WHERE a < 2 OR a >= 0",
"SELECT * FROM t WHERE a >= 2 AND a < 0",
"SELECT * FROM t WHERE NOT (a < 2 OR a >= 0)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a < 0)",
"SELECT * FROM t WHERE a <= 2 OR a > 0",
"SELECT * FROM t WHERE a > 2 AND a <= 0",
"SELECT * FROM t WHERE NOT (a <= 2 OR a > 0)",
"SELECT * FROM t WHERE NOT (a > 2 AND a <= 0)",
"SELECT * FROM t WHERE a <= 2 OR a >= 0",
"SELECT * FROM t WHERE a >= 2 AND a <= 0",
"SELECT * FROM t WHERE NOT (a <= 2 OR a >= 0)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a <= 0)",
"SELECT * FROM t WHERE a < 1",
"SELECT * FROM t WHERE a > 1",
"SELECT * FROM t WHERE a <= 1",
"SELECT * FROM t WHERE a >= 1",
"SELECT * FROM t WHERE a < 2 OR a > 1",
"SELECT * FROM t WHERE a > 2 AND a < 1",
"SELECT * FROM t WHERE NOT (a < 2 OR a > 1)",
"SELECT * FROM t WHERE NOT (a > 2 AND a < 1)",
"SELECT * FROM t WHERE a < 2 OR a >= 1",
"SELECT * FROM t WHERE a >= 2 AND a < 1",
"SELECT * FROM t WHERE NOT (a < 2 OR a >= 1)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a < 1)",
"SELECT * FROM t WHERE a <= 2 OR a > 1",
"SELECT * FROM t WHERE a > 2 AND a <= 1",
"SELECT * FROM t WHERE NOT (a <= 2 OR a > 1)",
"SELECT * FROM t WHERE NOT (a > 2 AND a <= 1)",
"SELECT * FROM t WHERE a <= 2 OR a >= 1",
"SELECT * FROM t WHERE a >= 2 AND a <= 1",
"SELECT * FROM t WHERE NOT (a <= 2 OR a >= 1)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a <= 1)",
"SELECT * FROM t WHERE a < 2",
"SELECT * FROM t WHERE a > 2",
"SELECT * FROM t WHERE a <= 2",
"SELECT * FROM t WHERE a >= 2",
"SELECT * FROM t WHERE a < 2 OR a > 2",
"SELECT * FROM t WHERE a > 2 AND a < 2",
"SELECT * FROM t WHERE NOT (a < 2 OR a > 2)",
"SELECT * FROM t WHERE NOT (a > 2 AND a < 2)",
"SELECT * FROM t WHERE a < 2 OR a >= 2",
"SELECT * FROM t WHERE a >= 2 AND a < 2",
"SELECT * FROM t WHERE NOT (a < 2 OR a >= 2)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a < 2)",
"SELECT * FROM t WHERE a <= 2 OR a > 2",
"SELECT * FROM t WHERE a > 2 AND a <= 2",
"SELECT * FROM t WHERE NOT (a <= 2 OR a > 2)",
"SELECT * FROM t WHERE NOT (a > 2 AND a <= 2)",
"SELECT * FROM t WHERE a <= 2 OR a >= 2",
"SELECT * FROM t WHERE a >= 2 AND a <= 2",
"SELECT * FROM t WHERE NOT (a <= 2 OR a >= 2)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a <= 2)",
"SELECT * FROM t WHERE a < 3",
"SELECT * FROM t WHERE a > 3",
"SELECT * FROM t WHERE a <= 3",
"SELECT * FROM t WHERE a >= 3",
"SELECT * FROM t WHERE a < 2 OR a > 3",
"SELECT * FROM t WHERE a > 2 AND a < 3",
"SELECT * FROM t WHERE NOT (a < 2 OR a > 3)",
"SELECT * FROM t WHERE NOT (a > 2 AND a < 3)",
"SELECT * FROM t WHERE a < 2 OR a >= 3",
"SELECT * FROM t WHERE a >= 2 AND a < 3",
"SELECT * FROM t WHERE NOT (a < 2 OR a >= 3)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a < 3)",
"SELECT * FROM t WHERE a <= 2 OR a > 3",
"SELECT * FROM t WHERE a > 2 AND a <= 3",
"SELECT * FROM t WHERE NOT (a <= 2 OR a > 3)",
"SELECT * FROM t WHERE NOT (a > 2 AND a <= 3)",
"SELECT * FROM t WHERE a <= 2 OR a >= 3",
"SELECT * FROM t WHERE a >= 2 AND a <= 3",
"SELECT * FROM t WHERE NOT (a <= 2 OR a >= 3)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a <= 3)",
"SELECT * FROM t WHERE a < 4",
"SELECT * FROM t WHERE a > 4",
"SELECT * FROM t WHERE a <= 4",
"SELECT * FROM t WHERE a >= 4",
"SELECT * FROM t WHERE a < 2 OR a > 4",
"SELECT * FROM t WHERE a > 2 AND a < 4",
"SELECT * FROM t WHERE NOT (a < 2 OR a > 4)",
"SELECT * FROM t WHERE NOT (a > 2 AND a < 4)",
"SELECT * FROM t WHERE a < 2 OR a >= 4",
"SELECT * FROM t WHERE a >= 2 AND a < 4",
"SELECT * FROM t WHERE NOT (a < 2 OR a >= 4)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a < 4)",
"SELECT * FROM t WHERE a <= 2 OR a > 4",
"SELECT * FROM t WHERE a > 2 AND a <= 4",
"SELECT * FROM t WHERE NOT (a <= 2 OR a > 4)",
"SELECT * FROM t WHERE NOT (a > 2 AND a <= 4)",
"SELECT * FROM t WHERE a <= 2 OR a >= 4",
"SELECT * FROM t WHERE a >= 2 AND a <= 4",
"SELECT * FROM t WHERE NOT (a <= 2 OR a >= 4)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a <= 4)",
"SELECT * FROM t WHERE a < 5",
"SELECT * FROM t WHERE a > 5",
"SELECT * FROM t WHERE a <= 5",
"SELECT * FROM t WHERE a >= 5",
"SELECT * FROM t WHERE a < 2 OR a > 5",
"SELECT * FROM t WHERE a > 2 AND a < 5",
"SELECT * FROM t WHERE NOT (a < 2 OR a > 5)",
"SELECT * FROM t WHERE NOT (a > 2 AND a < 5)",
"SELECT * FROM t WHERE a < 2 OR a >= 5",
"SELECT * FROM t WHERE a >= 2 AND a < 5",
"SELECT * FROM t WHERE NOT (a < 2 OR a >= 5)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a < 5)",
"SELECT * FROM t WHERE a <= 2 OR a > 5",
"SELECT * FROM t WHERE a > 2 AND a <= 5",
"SELECT * FROM t WHERE NOT (a <= 2 OR a > 5)",
"SELECT * FROM t WHERE NOT (a > 2 AND a <= 5)",
"SELECT * FROM t WHERE a <= 2 OR a >= 5",
"SELECT * FROM t WHERE a >= 2 AND a <= 5",
"SELECT * FROM t WHERE NOT (a <= 2 OR a >= 5)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a <= 5)",
"SELECT * FROM t WHERE a < 6",
"SELECT * FROM t WHERE a > 6",
"SELECT * FROM t WHERE a <= 6",
"SELECT * FROM t WHERE a >= 6",
"SELECT * FROM t WHERE a < 2 OR a > 6",
"SELECT * FROM t WHERE a > 2 AND a < 6",
"SELECT * FROM t WHERE NOT (a < 2 OR a > 6)",
"SELECT * FROM t WHERE NOT (a > 2 AND a < 6)",
"SELECT * FROM t WHERE a < 2 OR a >= 6",
"SELECT * FROM t WHERE a >= 2 AND a < 6",
"SELECT * FROM t WHERE NOT (a < 2 OR a >= 6)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a < 6)",
"SELECT * FROM t WHERE a <= 2 OR a > 6",
"SELECT * FROM t WHERE a > 2 AND a <= 6",
"SELECT * FROM t WHERE NOT (a <= 2 OR a > 6)",
"SELECT * FROM t WHERE NOT (a > 2 AND a <= 6)",
"SELECT * FROM t WHERE a <= 2 OR a >= 6",
"SELECT * FROM t WHERE a >= 2 AND a <= 6",
"SELECT * FROM t WHERE NOT (a <= 2 OR a >= 6)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a <= 6)",
"SELECT * FROM t WHERE a < 7",
"SELECT * FROM t WHERE a > 7",
"SELECT * FROM t WHERE a <= 7",
"SELECT * FROM t WHERE a >= 7",
"SELECT * FROM t WHERE a < 2 OR a > 7",
"SELECT * FROM t WHERE a > 2 AND a < 7",
"SELECT * FROM t WHERE NOT (a < 2 OR a > 7)",
"SELECT * FROM t WHERE NOT (a > 2 AND a < 7)",
"SELECT * FROM t WHERE a < 2 OR a >= 7",
"SELECT * FROM t WHERE a >= 2 AND a < 7",
"SELECT * FROM t WHERE NOT (a < 2 OR a >= 7)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a < 7)",
"SELECT * FROM t WHERE a <= 2 OR a > 7",
"SELECT * FROM t WHERE a > 2 AND a <= 7",
"SELECT * FROM t WHERE NOT (a <= 2 OR a > 7)",
"SELECT * FROM t WHERE NOT (a > 2 AND a <= 7)",
"SELECT * FROM t WHERE a <= 2 OR a >= 7",
"SELECT * FROM t WHERE a >= 2 AND a <= 7",
"SELECT * FROM t WHERE NOT (a <= 2 OR a >= 7)",
"SELECT * FROM t WHERE NOT (a >= 2 AND a <= 7)"
]
}
]
Loading