From 04021cda0a288c0932cf6cd587b946cc6528d8f0 Mon Sep 17 00:00:00 2001 From: joocer Date: Tue, 7 Nov 2023 18:46:11 +0000 Subject: [PATCH] #1245 --- tests/storage/test_cache_in_memory.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/storage/test_cache_in_memory.py b/tests/storage/test_cache_in_memory.py index 1ea372544..477979917 100644 --- a/tests/storage/test_cache_in_memory.py +++ b/tests/storage/test_cache_in_memory.py @@ -61,7 +61,7 @@ def test_cache_in_subqueries(): # read the data once, this should populate the cache conn = opteryx.connect() cur = conn.cursor() - cur.execute("SELECT * FROM (SELECT * FROM testdata.flat.tweets WITH(NO_PARTITION));") + cur.execute("SELECT * FROM (SELECT * FROM testdata.flat.tweets WITH(NO_PARTITION)) AS SQ;") cur.arrow() stats = cur.stats @@ -72,7 +72,7 @@ def test_cache_in_subqueries(): # read the data a second time, this should hit the cache conn = opteryx.connect() cur = conn.cursor() - cur.execute("SELECT * FROM (SELECT * FROM testdata.flat.tweets WITH(NO_PARTITION));") + cur.execute("SELECT * FROM (SELECT * FROM testdata.flat.tweets WITH(NO_PARTITION)) AS SQ;") cur.arrow() stats = cur.stats @@ -83,7 +83,9 @@ def test_cache_in_subqueries(): # read the data with the no cache directive conn = opteryx.connect() cur = conn.cursor() - cur.execute("SELECT * FROM (SELECT * FROM testdata.flat.tweets WITH(NO_CACHE, NO_PARTITION));") + cur.execute( + "SELECT * FROM (SELECT * FROM testdata.flat.tweets WITH(NO_CACHE, NO_PARTITION)) AS SQ;" + ) cur.arrow() stats = cur.stats