diff --git a/snuba/cli/query_fetcher.py b/snuba/cli/query_fetcher.py index 3d54bd7fb5..1d4d0a9ab6 100644 --- a/snuba/cli/query_fetcher.py +++ b/snuba/cli/query_fetcher.py @@ -152,8 +152,8 @@ def get_queries_from_querylog( window_hours_ago_ts = now - timedelta(hours=window_hours) interval = timedelta(hours=1) - start_time = window_hours_ago_ts for table in table_names: + start_time = window_hours_ago_ts while start_time < now: end_time = start_time + interval logger.info(f"Fetching queries to run from {table}...")