summaryrefslogtreecommitdiffstats
path: root/tests/fixtures/optimizer/simplify.sql
diff options
context:
space:
mode:
Diffstat (limited to 'tests/fixtures/optimizer/simplify.sql')
-rw-r--r--tests/fixtures/optimizer/simplify.sql16
1 files changed, 14 insertions, 2 deletions
diff --git a/tests/fixtures/optimizer/simplify.sql b/tests/fixtures/optimizer/simplify.sql
index 4e9e70c..08e8700 100644
--- a/tests/fixtures/optimizer/simplify.sql
+++ b/tests/fixtures/optimizer/simplify.sql
@@ -141,6 +141,9 @@ A OR C;
(A OR C) AND (A OR B OR C);
A OR C;
+A AND (B AND C) AND (D AND E);
+A AND B AND C AND D AND E;
+
--------------------------------------
-- Elimination
--------------------------------------
@@ -249,6 +252,12 @@ x = x;
(('a' = 'a') AND TRUE and NOT FALSE);
TRUE;
+(x = y) and z;
+x = y AND z;
+
+x * (1 - y);
+x * (1 - y);
+
--------------------------------------
-- Literals
--------------------------------------
@@ -310,7 +319,7 @@ TRUE;
8.0;
6 - 2 + 4 * 2 + a;
-12 + a;
+a + 12;
a + 1 + 1 + 2;
a + 4;
@@ -367,7 +376,7 @@ interval '1' year + date '1998-01-01';
CAST('1999-01-01' AS DATE);
interval '1' year + date '1998-01-01' + 3 * 7 * 4;
-CAST('1999-01-01' AS DATE) + 84;
+84 + CAST('1999-01-01' AS DATE);
date '1998-12-01' - interval '90' foo;
CAST('1998-12-01' AS DATE) - INTERVAL '90' foo;
@@ -554,3 +563,6 @@ x <= 10 AND x >= 9;
1 < x AND 3 < x;
x > 3;
+
+'a' < 'b';
+TRUE;