summaryrefslogtreecommitdiffstats
path: root/tests/test_transforms.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_transforms.py')
-rw-r--r--tests/test_transforms.py5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/test_transforms.py b/tests/test_transforms.py
index 1e85b80..24d8c30 100644
--- a/tests/test_transforms.py
+++ b/tests/test_transforms.py
@@ -106,6 +106,11 @@ class TestTransforms(unittest.TestCase):
"SELECT c2, SUM(c3) OVER (PARTITION BY c2) AS r FROM t1 WHERE c3 < 4 GROUP BY c2, c3 HAVING SUM(c1) > 3 QUALIFY r IN (SELECT MIN(c1) FROM test GROUP BY c2 HAVING MIN(c1) > 3)",
"SELECT c2, r FROM (SELECT c2, SUM(c3) OVER (PARTITION BY c2) AS r, c1 FROM t1 WHERE c3 < 4 GROUP BY c2, c3 HAVING SUM(c1) > 3) AS _t WHERE r IN (SELECT MIN(c1) FROM test GROUP BY c2 HAVING MIN(c1) > 3)",
)
+ self.validate(
+ eliminate_qualify,
+ "SELECT x FROM y QUALIFY ROW_NUMBER() OVER (PARTITION BY p)",
+ "SELECT x FROM (SELECT x, ROW_NUMBER() OVER (PARTITION BY p) AS _w, p FROM y) AS _t WHERE _w",
+ )
def test_remove_precision_parameterized_types(self):
self.validate(