Skip to content

Commit

Permalink
parser, expression: follow mysql, increase interval precedence (#30528)
Browse files Browse the repository at this point in the history
  • Loading branch information
Defined2014 authored Dec 9, 2021
1 parent 80ea238 commit 05f7c6d
Show file tree
Hide file tree
Showing 4 changed files with 645 additions and 645 deletions.
2 changes: 2 additions & 0 deletions expression/integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3978,6 +3978,8 @@ func (s *testIntegrationSuite) TestCompareBuiltin(c *C) {
result.Check(testkit.Rows("1 1 1"))
result = tk.MustQuery(`select INTERVAL(100, NULL, NULL, NULL, NULL, NULL, 100);`)
result.Check(testkit.Rows("6"))
result = tk.MustQuery(`SELECT INTERVAL(0,(1*5)/2) + INTERVAL(5,4,3);`)
result.Check(testkit.Rows("2"))

// for greatest
result = tk.MustQuery(`select greatest(1, 2, 3), greatest("a", "b", "c"), greatest(1.1, 1.2, 1.3), greatest("123a", 1, 2)`)
Expand Down
Loading

0 comments on commit 05f7c6d

Please sign in to comment.