From 472536af1d517029bd928103e0954bf9a1faa053 Mon Sep 17 00:00:00 2001 From: Sandy Spicer Date: Mon, 5 Aug 2024 09:01:23 -0700 Subject: [PATCH] fix: max query size (#24148) --- ...t_session_recording_list_from_filters.ambr | 180 ++--- .../api/test/__snapshots__/test_query.ambr | 160 ++--- posthog/clickhouse/client/execute.py | 3 + .../__snapshots__/test_execute_async.ambr | 5 +- .../test/__snapshots__/test_heatmaps_api.ambr | 150 ++--- posthog/hogql/constants.py | 5 +- .../test_session_replay_events.ambr | 70 +- posthog/hogql/database/test/test_database.py | 2 +- .../test/__snapshots__/test_cohort.ambr | 6 +- .../hogql/functions/test/test_sparkline.py | 2 +- .../hogql/test/__snapshots__/test_query.ambr | 76 +-- posthog/hogql/test/test_printer.py | 33 +- posthog/hogql/test/test_query.py | 2 +- .../test/__snapshots__/test_in_cohort.ambr | 12 +- posthog/hogql_queries/actors_query_runner.py | 6 +- .../test/__snapshots__/test_funnel.ambr | 251 +------ ...test_funnel_breakdowns_by_current_url.ambr | 10 +- .../test_funnel_correlation.ambr | 335 ++++------ .../test_funnel_correlations_persons.ambr | 50 +- .../__snapshots__/test_funnel_persons.ambr | 165 +---- .../__snapshots__/test_funnel_strict.ambr | 30 +- .../test_funnel_strict_persons.ambr | 141 +--- .../test_funnel_time_to_convert.ambr | 15 +- .../__snapshots__/test_funnel_trends.ambr | 15 +- .../test_funnel_trends_persons.ambr | 156 +---- .../__snapshots__/test_funnel_unordered.ambr | 30 +- .../test_funnel_unordered_persons.ambr | 86 +-- .../test_insight_actors_query_runner.ambr | 75 +-- .../test_lifecycle_query_runner.ambr | 20 +- .../test_paths_query_runner_ee.ambr | 275 ++++---- .../test_retention_query_runner.ambr | 70 +- .../test/__snapshots__/test_trends.ambr | 615 +++++++----------- .../test_trends_data_warehouse_query.ambr | 25 +- .../test_error_tracking_query_runner.ambr | 30 +- .../test_sessions_timeline_query_runner.ambr | 35 +- ...t_session_recording_list_from_filters.ambr | 590 +++++++---------- 36 files changed, 1263 insertions(+), 2468 deletions(-) diff --git a/ee/session_recordings/queries/test/__snapshots__/test_session_recording_list_from_filters.ambr b/ee/session_recordings/queries/test/__snapshots__/test_session_recording_list_from_filters.ambr index fb9003b341b61..fd0b7d5358f5f 100644 --- a/ee/session_recordings/queries/test/__snapshots__/test_session_recording_list_from_filters.ambr +++ b/ee/session_recordings/queries/test/__snapshots__/test_session_recording_list_from_filters.ambr @@ -194,9 +194,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -232,9 +231,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -265,9 +263,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -303,9 +300,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -336,9 +332,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -374,9 +369,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -407,9 +401,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -445,9 +438,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -478,9 +470,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -528,9 +519,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -561,9 +551,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -611,9 +600,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -644,9 +632,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -694,9 +681,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -727,9 +713,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -777,9 +762,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -810,9 +794,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -848,9 +831,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -881,9 +863,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -919,9 +900,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -952,9 +932,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -990,9 +969,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1023,9 +1001,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1061,9 +1038,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1097,9 +1073,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1133,9 +1108,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1169,9 +1143,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1205,9 +1178,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1246,9 +1218,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1287,9 +1258,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1328,9 +1298,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1369,9 +1338,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1411,9 +1379,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1453,9 +1420,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1495,9 +1461,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1537,9 +1502,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/api/test/__snapshots__/test_query.ambr b/posthog/api/test/__snapshots__/test_query.ambr index 4598a9a6a3253..fbea79986c2ba 100644 --- a/posthog/api/test/__snapshots__/test_query.ambr +++ b/posthog/api/test/__snapshots__/test_query.ambr @@ -15,9 +15,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -37,9 +36,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -59,9 +57,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -81,9 +78,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -103,9 +99,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -125,9 +120,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -143,9 +137,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -161,9 +154,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -179,9 +171,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -199,9 +190,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -219,9 +209,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -239,9 +228,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -263,9 +251,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -285,9 +272,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -307,9 +293,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -329,9 +314,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -351,9 +335,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -373,9 +356,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -395,9 +377,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -417,9 +398,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -439,9 +419,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -479,9 +458,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -519,9 +497,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -539,9 +516,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -560,9 +536,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -580,9 +555,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -601,9 +575,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -621,9 +594,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -642,9 +614,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -661,9 +632,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -681,9 +651,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -701,9 +670,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/clickhouse/client/execute.py b/posthog/clickhouse/client/execute.py index 317fa66755e8a..1fcc1402c948a 100644 --- a/posthog/clickhouse/client/execute.py +++ b/posthog/clickhouse/client/execute.py @@ -47,6 +47,9 @@ def default_settings() -> dict: return { "join_algorithm": "direct,parallel_hash,hash", "distributed_replica_max_ignored_errors": 1000, + # max_query_size can't be set in a query, because it determines the size of the buffer used to parse the query + # https://clickhouse.com/docs/en/operations/settings/settings#max_query_size + "max_query_size": 1048576, } diff --git a/posthog/clickhouse/client/test/__snapshots__/test_execute_async.ambr b/posthog/clickhouse/client/test/__snapshots__/test_execute_async.ambr index 82072cc8ef027..4eebf577dab69 100644 --- a/posthog/clickhouse/client/test/__snapshots__/test_execute_async.ambr +++ b/posthog/clickhouse/client/test/__snapshots__/test_execute_async.ambr @@ -7,9 +7,8 @@ max_execution_time=600, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/heatmaps/test/__snapshots__/test_heatmaps_api.ambr b/posthog/heatmaps/test/__snapshots__/test_heatmaps_api.ambr index 2fa2e26e9e367..b53d60c32151f 100644 --- a/posthog/heatmaps/test/__snapshots__/test_heatmaps_api.ambr +++ b/posthog/heatmaps/test/__snapshots__/test_heatmaps_api.ambr @@ -20,9 +20,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -47,9 +46,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -74,9 +72,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -101,9 +98,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -128,9 +124,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -155,9 +150,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -182,9 +176,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -209,9 +202,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -236,9 +228,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -263,9 +254,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -290,9 +280,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -317,9 +306,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -344,9 +332,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -371,9 +358,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -398,9 +384,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -425,9 +410,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -452,9 +436,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -479,9 +462,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -506,9 +488,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -533,9 +514,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -560,9 +540,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -587,9 +566,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -614,9 +592,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -641,9 +618,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -668,9 +644,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -695,9 +670,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -722,9 +696,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -749,9 +722,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -776,9 +748,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -803,9 +774,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql/constants.py b/posthog/hogql/constants.py index 02e29cbfad351..557cbfd05c01e 100644 --- a/posthog/hogql/constants.py +++ b/posthog/hogql/constants.py @@ -101,8 +101,7 @@ class HogQLGlobalSettings(HogQLQuerySettings): max_execution_time: Optional[int] = 60 allow_experimental_object_type: Optional[bool] = True format_csv_allow_double_quotes: Optional[bool] = False - max_ast_elements: Optional[int] = 2_000_000 # default value 50000 - max_expanded_ast_elements: Optional[int] = 2_000_000 - max_query_size: Optional[int] = 262144 * 4 # default value 262144 (= 256 KiB) + max_ast_elements: Optional[int] = 4_000_000 # default value 50000 + max_expanded_ast_elements: Optional[int] = 4_000_000 max_bytes_before_external_group_by: Optional[int] = 0 # default value means we don't swap ordering by to disk allow_experimental_analyzer: Optional[bool] = None diff --git a/posthog/hogql/database/schema/test/__snapshots__/test_session_replay_events.ambr b/posthog/hogql/database/schema/test/__snapshots__/test_session_replay_events.ambr index 1cbecfd53c1f5..95d6d8919921d 100644 --- a/posthog/hogql/database/schema/test/__snapshots__/test_session_replay_events.ambr +++ b/posthog/hogql/database/schema/test/__snapshots__/test_session_replay_events.ambr @@ -17,9 +17,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -43,9 +42,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -69,9 +67,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -90,9 +87,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -111,9 +107,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -134,9 +129,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -173,9 +167,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -196,9 +189,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -226,9 +218,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -262,9 +253,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -298,9 +288,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -334,9 +323,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -359,9 +347,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -377,9 +364,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql/database/test/test_database.py b/posthog/hogql/database/test/test_database.py index 661c36d2e4d5a..73d86544f5c33 100644 --- a/posthog/hogql/database/test/test_database.py +++ b/posthog/hogql/database/test/test_database.py @@ -216,7 +216,7 @@ def test_database_with_warehouse_tables(self, patch_execute): self.assertEqual( response.clickhouse, - f"SELECT whatever.id AS id FROM s3(%(hogql_val_0_sensitive)s, %(hogql_val_3_sensitive)s, %(hogql_val_4_sensitive)s, %(hogql_val_1)s, %(hogql_val_2)s) AS whatever LIMIT 100 SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0", + f"SELECT whatever.id AS id FROM s3(%(hogql_val_0_sensitive)s, %(hogql_val_3_sensitive)s, %(hogql_val_4_sensitive)s, %(hogql_val_1)s, %(hogql_val_2)s) AS whatever LIMIT 100 SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0", ) def test_database_group_type_mappings(self): diff --git a/posthog/hogql/functions/test/__snapshots__/test_cohort.ambr b/posthog/hogql/functions/test/__snapshots__/test_cohort.ambr index bd4cef607d721..58f4492899fa8 100644 --- a/posthog/hogql/functions/test/__snapshots__/test_cohort.ambr +++ b/posthog/hogql/functions/test/__snapshots__/test_cohort.ambr @@ -12,7 +12,7 @@ GROUP BY cohortpeople.person_id, cohortpeople.cohort_id, cohortpeople.version HAVING ifNull(greater(sum(cohortpeople.sign), 0), 0))), equals(events.event, %(hogql_val_0)s)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -38,7 +38,7 @@ FROM person_static_cohort WHERE and(equals(person_static_cohort.team_id, 420), equals(person_static_cohort.cohort_id, XX))))) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -62,7 +62,7 @@ FROM person_static_cohort WHERE and(equals(person_static_cohort.team_id, 420), equals(person_static_cohort.cohort_id, XX))))) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL diff --git a/posthog/hogql/functions/test/test_sparkline.py b/posthog/hogql/functions/test/test_sparkline.py index 9e5dfdb33042a..c7dfa946140e5 100644 --- a/posthog/hogql/functions/test/test_sparkline.py +++ b/posthog/hogql/functions/test/test_sparkline.py @@ -8,7 +8,7 @@ def test_sparkline(self): response = execute_hogql_query("select sparkline([1,2,3])", self.team, pretty=False) self.assertEqual( response.clickhouse, - f"SELECT tuple(%(hogql_val_0)s, %(hogql_val_1)s, %(hogql_val_2)s, [1, 2, 3]) LIMIT 100 SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0", + f"SELECT tuple(%(hogql_val_0)s, %(hogql_val_1)s, %(hogql_val_2)s, [1, 2, 3]) LIMIT 100 SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0", ) self.assertEqual( response.hogql, diff --git a/posthog/hogql/test/__snapshots__/test_query.ambr b/posthog/hogql/test/__snapshots__/test_query.ambr index a5ae80eee4644..24ff3ec47cb6e 100644 --- a/posthog/hogql/test/__snapshots__/test_query.ambr +++ b/posthog/hogql/test/__snapshots__/test_query.ambr @@ -5,7 +5,7 @@ SELECT [1, 2, 3], [10, 11, 12][1] LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -19,7 +19,7 @@ SELECT arrayMap(x -> multiply(x, 2), [1, 2, 3]), 1 LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -35,7 +35,7 @@ FROM events WHERE and(equals(events.team_id, 420), equals(events.distinct_id, %(hogql_val_0)s), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(events.properties, %(hogql_val_1)s), ''), 'null'), '^"|"$', ''), %(hogql_val_2)s), 0)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -62,7 +62,7 @@ FROM events WHERE and(equals(events.team_id, 420), equals(events.distinct_id, %(hogql_val_0)s), and(ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(events.properties, %(hogql_val_1)s), ''), 'null'), '^"|"$', ''), %(hogql_val_2)s), 0), less(toTimeZone(events.timestamp, %(hogql_val_3)s), toDateTime64('2020-01-02 00:00:00.000000', 6, 'UTC')), greaterOrEquals(toTimeZone(events.timestamp, %(hogql_val_4)s), toDateTime64('2020-01-01 00:00:00.000000', 6, 'UTC')))) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -89,7 +89,7 @@ FROM events AS e WHERE and(equals(e.team_id, 420), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, %(hogql_val_0)s), ''), 'null'), '^"|"$', ''), %(hogql_val_1)s), 0)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -111,7 +111,7 @@ GROUP BY sessions.session_id, sessions.session_id) AS sessions WHERE and(ifNull(less(sessions.`$start_timestamp`, toDateTime64('2024-07-06 00:00:00.000000', 6, 'UTC')), 0), ifNull(greaterOrEquals(sessions.`$start_timestamp`, toDateTime64('2024-07-04 00:00:00.000000', 6, 'UTC')), 0)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -142,7 +142,7 @@ GROUP BY sessions.session_id, sessions.session_id) AS sessions WHERE and(ifNull(equals(sessions.`$entry_current_url`, %(hogql_val_2)s), 0), 1) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -173,7 +173,7 @@ FROM events WHERE equals(events.team_id, 420) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -197,7 +197,7 @@ GROUP BY session_replay_events.session_id) AS s ON equals(s.session_id, nullIf(nullIf(e.`$session_id`, ''), 'null')) WHERE and(equals(e.team_id, 420), isNotNull(nullIf(nullIf(e.`$session_id`, ''), 'null'))) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -228,7 +228,7 @@ GROUP BY session_replay_events.session_id) AS s LEFT JOIN events AS e ON equals(nullIf(nullIf(e.`$session_id`, ''), 'null'), s.session_id) WHERE and(equals(e.team_id, 420), isNotNull(nullIf(nullIf(e.`$session_id`, ''), 'null'))) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -259,7 +259,7 @@ GROUP BY session_replay_events.session_id) AS s ON equals(s.session_id, replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, %(hogql_val_0)s), ''), 'null'), '^"|"$', '')) WHERE and(equals(e.team_id, 420), isNotNull(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, %(hogql_val_1)s), ''), 'null'), '^"|"$', ''))) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -290,7 +290,7 @@ GROUP BY session_replay_events.session_id) AS s LEFT JOIN events AS e ON equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, %(hogql_val_0)s), ''), 'null'), '^"|"$', ''), s.session_id) WHERE and(equals(e.team_id, 420), isNotNull(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, %(hogql_val_1)s), ''), 'null'), '^"|"$', ''))) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -329,7 +329,7 @@ HAVING ifNull(greater(sum(cohortpeople.sign), 0), 0))), 0)) GROUP BY events.event LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -359,7 +359,7 @@ HAVING ifNull(greater(sum(cohortpeople.sign), 0), 0)))) GROUP BY events.event LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -393,7 +393,7 @@ WHERE and(equals(person_static_cohort.team_id, 420), equals(person_static_cohort.cohort_id, XX)))), 0)) GROUP BY events.event LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -419,7 +419,7 @@ WHERE and(equals(person_static_cohort.team_id, 420), equals(person_static_cohort.cohort_id, XX))))) GROUP BY events.event LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -442,7 +442,7 @@ WHERE and(equals(events.team_id, 420), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(events.properties, %(hogql_val_0)s), ''), 'null'), '^"|"$', ''), %(hogql_val_1)s), 0)) GROUP BY events.event LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -470,7 +470,7 @@ SETTINGS optimize_aggregation_in_order=1) AS persons WHERE ifNull(equals(persons.properties___random_uuid, %(hogql_val_4)s), 0) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -494,7 +494,7 @@ SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) WHERE equals(e.team_id, 420) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -517,7 +517,7 @@ SETTINGS optimize_aggregation_in_order=1) AS events__pdi ON equals(events.distinct_id, events__pdi.distinct_id) WHERE equals(events.team_id, 420) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -549,7 +549,7 @@ SETTINGS optimize_aggregation_in_order=1) AS e__pdi__person ON equals(e__pdi.e__pdi___person_id, e__pdi__person.id) WHERE equals(e.team_id, 420) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -578,7 +578,7 @@ SETTINGS optimize_aggregation_in_order=1) AS events__pdi__person ON equals(events__pdi.events__pdi___person_id, events__pdi__person.id) WHERE equals(events.team_id, 420) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -610,7 +610,7 @@ SETTINGS optimize_aggregation_in_order=1) AS events__pdi__person ON equals(events__pdi.events__pdi___person_id, events__pdi__person.id) WHERE equals(events.team_id, 420) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -642,7 +642,7 @@ SETTINGS optimize_aggregation_in_order=1) AS e__pdi__person ON equals(e__pdi.e__pdi___person_id, e__pdi__person.id) WHERE equals(e.team_id, 420) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -675,7 +675,7 @@ WHERE equals(s.team_id, 420) GROUP BY s__pdi__person.properties___sneaky_mail LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -698,7 +698,7 @@ HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0)) AS pdi ON equals(e.distinct_id, pdi.distinct_id) WHERE equals(e.team_id, 420) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -733,7 +733,7 @@ HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, %(hogql_val_1)s), person.version), plus(now64(6, %(hogql_val_2)s), toIntervalDay(1))), 0)))), 0)) SETTINGS optimize_aggregation_in_order=1) AS pdi__person ON equals(pdi.pdi___person_id, pdi__person.id) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -761,7 +761,7 @@ HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, %(hogql_val_1)s), person.version), plus(now64(6, %(hogql_val_2)s), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS pdi__person ON equals(pdi.pdi___person_id, pdi__person.id) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -793,7 +793,7 @@ SETTINGS optimize_aggregation_in_order=1) AS p ON equals(p.id, pdi.person_id) WHERE equals(e.team_id, 420) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -815,7 +815,7 @@ HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS person_distinct_ids LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -847,7 +847,7 @@ SETTINGS optimize_aggregation_in_order=1) AS events__pdi__person ON equals(events__pdi.events__pdi___person_id, events__pdi__person.id) WHERE equals(events.team_id, 420) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -864,7 +864,7 @@ FROM events WHERE equals(events.team_id, 420) LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -882,7 +882,7 @@ WHERE equals(s.team_id, 420) GROUP BY replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(s.person_properties, %(hogql_val_1)s), ''), 'null'), '^"|"$', '') LIMIT 10 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -904,7 +904,7 @@ GROUP BY events.event) GROUP BY count, event LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -930,7 +930,7 @@ GROUP BY events.event) AS c GROUP BY c.count, c.event LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -959,7 +959,7 @@ GROUP BY col_a) GROUP BY col_a ORDER BY col_a ASC LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -992,7 +992,7 @@ GROUP BY PIVOT_TABLE_COL_ABC.col_a) AS PIVOT_FUNCTION_1 GROUP BY PIVOT_FUNCTION_1.col_a) AS PIVOT_FUNCTION_2 ORDER BY PIVOT_FUNCTION_2.col_a ASC LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -1029,7 +1029,7 @@ GROUP BY PIVOT_TABLE_COL_ABC.col_a) AS PIVOT_FUNCTION_1 GROUP BY PIVOT_FUNCTION_1.col_a) AS PIVOT_FUNCTION_2) AS final ORDER BY final.col_a ASC LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL diff --git a/posthog/hogql/test/test_printer.py b/posthog/hogql/test/test_printer.py index 3fd48af45f147..800557e780a41 100644 --- a/posthog/hogql/test/test_printer.py +++ b/posthog/hogql/test/test_printer.py @@ -1238,7 +1238,7 @@ def test_print_global_settings(self): ) self.assertEqual( printed, - f"SELECT 1 FROM events WHERE equals(events.team_id, {self.team.pk}) LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0", + f"SELECT 1 FROM events WHERE equals(events.team_id, {self.team.pk}) LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0", ) def test_print_query_level_settings(self): @@ -1265,7 +1265,7 @@ def test_print_both_settings(self): ) self.assertEqual( printed, - f"SELECT 1 FROM events WHERE equals(events.team_id, {self.team.pk}) LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS optimize_aggregation_in_order=1, readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0", + f"SELECT 1 FROM events WHERE equals(events.team_id, {self.team.pk}) LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS optimize_aggregation_in_order=1, readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0", ) def test_pretty_print(self): @@ -1368,7 +1368,7 @@ def test_print_hidden_aliases_timestamp(self): printed, f"SELECT timestamp AS timestamp FROM (SELECT toTimeZone(events.timestamp, %(hogql_val_0)s), " f"toTimeZone(events.timestamp, %(hogql_val_1)s) AS timestamp FROM events WHERE equals(events.team_id, {self.team.pk})) " - f"LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0", + f"LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0", ) def test_print_hidden_aliases_column_override(self): @@ -1383,7 +1383,7 @@ def test_print_hidden_aliases_column_override(self): printed, f"SELECT event AS event FROM (SELECT toTimeZone(events.timestamp, %(hogql_val_0)s) AS event, " f"event FROM events WHERE equals(events.team_id, {self.team.pk})) " - f"LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0", + f"LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0", ) def test_print_hidden_aliases_properties(self): @@ -1406,7 +1406,7 @@ def test_print_hidden_aliases_properties(self): printed, f"SELECT `$browser` AS `$browser` FROM (SELECT nullIf(nullIf(events.`mat_$browser`, ''), 'null') AS `$browser` " f"FROM events WHERE equals(events.team_id, {self.team.pk})) LIMIT {MAX_SELECT_RETURNED_ROWS} " - f"SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0", + f"SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0", ) def test_print_hidden_aliases_double_property(self): @@ -1430,7 +1430,7 @@ def test_print_hidden_aliases_double_property(self): f"SELECT `$browser` AS `$browser` FROM (SELECT nullIf(nullIf(events.`mat_$browser`, ''), 'null'), " f"nullIf(nullIf(events.`mat_$browser`, ''), 'null') AS `$browser` " # only the second one gets the alias f"FROM events WHERE equals(events.team_id, {self.team.pk})) LIMIT {MAX_SELECT_RETURNED_ROWS} " - f"SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0", + f"SETTINGS readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0", ) def test_lookup_domain_type(self): @@ -1449,9 +1449,8 @@ def test_lookup_domain_type(self): "(cutToFirstSignificantSubdomain(coalesce(%(hogql_val_0)s, '')), 'source'))) " f"FROM events WHERE equals(events.team_id, {self.team.pk}) LIMIT 50000 SETTINGS " "readonly=2, max_execution_time=10, allow_experimental_object_type=1, " - "format_csv_allow_double_quotes=0, max_ast_elements=2000000, " - "max_expanded_ast_elements=2000000, max_query_size=1048576, " - "max_bytes_before_external_group_by=0" + "format_csv_allow_double_quotes=0, max_ast_elements=4000000, " + "max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0" ), printed, ) @@ -1472,9 +1471,8 @@ def test_lookup_paid_source_type(self): "(cutToFirstSignificantSubdomain(coalesce(%(hogql_val_0)s, '')), 'source'))) " f"FROM events WHERE equals(events.team_id, {self.team.pk}) LIMIT 50000 SETTINGS " "readonly=2, max_execution_time=10, allow_experimental_object_type=1, " - "format_csv_allow_double_quotes=0, max_ast_elements=2000000, " - "max_expanded_ast_elements=2000000, max_query_size=1048576, " - "max_bytes_before_external_group_by=0" + "format_csv_allow_double_quotes=0, max_ast_elements=4000000, " + "max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0" ), printed, ) @@ -1492,7 +1490,7 @@ def test_lookup_paid_medium_type(self): "SELECT dictGetOrNull('channel_definition_dict', 'type_if_paid', " "(coalesce(%(hogql_val_0)s, ''), 'medium')) " f"FROM events WHERE equals(events.team_id, {self.team.pk}) LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS " - "readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0" + "readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0" ), printed, ) @@ -1513,9 +1511,8 @@ def test_lookup_organic_source_type(self): "(cutToFirstSignificantSubdomain(coalesce(%(hogql_val_0)s, '')), 'source'))) " f"FROM events WHERE equals(events.team_id, {self.team.pk}) LIMIT 50000 SETTINGS " "readonly=2, max_execution_time=10, allow_experimental_object_type=1, " - "format_csv_allow_double_quotes=0, max_ast_elements=2000000, " - "max_expanded_ast_elements=2000000, max_query_size=1048576, " - "max_bytes_before_external_group_by=0" + "format_csv_allow_double_quotes=0, max_ast_elements=4000000, " + "max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0" ), printed, ) @@ -1533,7 +1530,7 @@ def test_lookup_organic_medium_type(self): "SELECT dictGetOrNull('channel_definition_dict', 'type_if_organic', " "(coalesce(%(hogql_val_0)s, ''), 'medium')) " f"FROM events WHERE equals(events.team_id, {self.team.pk}) LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS " - "readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0" + "readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0" ), printed, ) @@ -1584,7 +1581,7 @@ def test_trim_leading_trailing_both(self): ) assert printed == ( f"SELECT trim(LEADING %(hogql_val_1)s FROM %(hogql_val_0)s), trim(TRAILING %(hogql_val_3)s FROM %(hogql_val_2)s), trim(BOTH %(hogql_val_5)s FROM %(hogql_val_4)s) LIMIT {MAX_SELECT_RETURNED_ROWS} SETTINGS " - "readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0" + "readonly=2, max_execution_time=10, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0" ) query2 = parse_select("select trimLeft('media', 'xy'), trimRight('media', 'xy'), trim('media', 'xy')") printed2 = print_ast( diff --git a/posthog/hogql/test/test_query.py b/posthog/hogql/test/test_query.py index 2fcc347dd36b7..772024ab53d8d 100644 --- a/posthog/hogql/test/test_query.py +++ b/posthog/hogql/test/test_query.py @@ -1015,7 +1015,7 @@ def test_property_access_with_arrays(self): f"FROM events " f"WHERE and(equals(events.team_id, {self.team.pk}), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(events.properties, %(hogql_val_46)s), ''), 'null'), '^\"|\"$', ''), %(hogql_val_47)s), 0)) " f"LIMIT 100 " - f"SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0", + f"SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0", response.clickhouse, ) self.assertEqual(response.results[0], tuple(random_uuid for x in alternatives)) diff --git a/posthog/hogql/transforms/test/__snapshots__/test_in_cohort.ambr b/posthog/hogql/transforms/test/__snapshots__/test_in_cohort.ambr index 474fa9e1c8037..66203f817267f 100644 --- a/posthog/hogql/transforms/test/__snapshots__/test_in_cohort.ambr +++ b/posthog/hogql/transforms/test/__snapshots__/test_in_cohort.ambr @@ -10,7 +10,7 @@ WHERE and(equals(cohortpeople.team_id, 420), equals(cohortpeople.cohort_id, XX), equals(cohortpeople.version, 0))) AS __in_cohort ON equals(__in_cohort.cohort_person_id, events.person_id) WHERE and(equals(events.team_id, 420), and(1, equals(events.event, %(hogql_val_0)s)), ifNull(equals(__in_cohort.matched, 1), 0)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -34,7 +34,7 @@ WHERE and(equals(person_static_cohort.team_id, 420), in(person_static_cohort.cohort_id, [13]))) AS __in_cohort ON equals(__in_cohort.cohort_person_id, events.person_id) WHERE and(equals(events.team_id, 420), 1, ifNull(equals(__in_cohort.matched, 1), 0)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -58,7 +58,7 @@ WHERE and(equals(person_static_cohort.team_id, 420), in(person_static_cohort.cohort_id, [14]))) AS __in_cohort ON equals(__in_cohort.cohort_person_id, events.person_id) WHERE and(equals(events.team_id, 420), 1, ifNull(equals(__in_cohort.matched, 1), 0)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -84,7 +84,7 @@ HAVING ifNull(greater(sum(cohortpeople.sign), 0), 0)) AS in_cohort__XX ON equals(in_cohort__XX.person_id, events.person_id) WHERE and(equals(events.team_id, 420), ifNull(equals(in_cohort__XX.matched, 1), 0), equals(events.event, %(hogql_val_0)s)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -110,7 +110,7 @@ WHERE and(equals(person_static_cohort.team_id, 420), equals(person_static_cohort.cohort_id, XX))) AS in_cohort__XX ON equals(in_cohort__XX.person_id, events.person_id) WHERE and(equals(events.team_id, 420), ifNull(equals(in_cohort__XX.matched, 1), 0)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL @@ -134,7 +134,7 @@ WHERE and(equals(person_static_cohort.team_id, 420), equals(person_static_cohort.cohort_id, XX))) AS in_cohort__XX ON equals(in_cohort__XX.person_id, events.person_id) WHERE and(equals(events.team_id, 420), ifNull(equals(in_cohort__XX.matched, 1), 0)) LIMIT 100 - SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=2000000, max_expanded_ast_elements=2000000, max_query_size=1048576, max_bytes_before_external_group_by=0 + SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, max_ast_elements=4000000, max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 -- HogQL diff --git a/posthog/hogql_queries/actors_query_runner.py b/posthog/hogql_queries/actors_query_runner.py index 4cda01240f19e..ba7301b5e0c51 100644 --- a/posthog/hogql_queries/actors_query_runner.py +++ b/posthog/hogql_queries/actors_query_runner.py @@ -267,7 +267,11 @@ def to_query(self) -> ast.SelectQuery: # For some of our users, the persons table is large. If we're looking for person, # help make the join smarter by limiting the people it has to look up # The persons table inlines `in` conditions on the join (see `persons.py`) - if isinstance(self.strategy, PersonStrategy): + # Funnels queries are very big. Don't do this for funnels as it blows up the query size. + if isinstance(self.strategy, PersonStrategy) and not ( + isinstance(self.source_query_runner, InsightActorsQueryRunner) + and isinstance(self.source_query_runner.source_runner, FunnelsQueryRunner) + ): join_on = ast.And( exprs=[ join_on, diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel.ambr index d733159ba5ee0..1dbe7a3fd269f 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel.ambr @@ -90,9 +90,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -189,41 +188,7 @@ (SELECT argMax(toTimeZone(person.created_at, 'UTC'), person.version) AS created_at, person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, latest_2 AS latest_2, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalSecond(15))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalSecond(15))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalSecond(15))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalSecond(15))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalSecond(15))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2 - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2 - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2 - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2 - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-05-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-05-14 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [2, 3]), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.created_at DESC @@ -232,9 +197,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -339,9 +303,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -427,9 +390,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -537,9 +499,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -648,50 +609,7 @@ (SELECT argMax(toTimeZone(person.created_at, 'UTC'), person.version) AS created_at, person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, latest_2 AS latest_2, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2 - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2 - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2 - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, if(equals(e.event, 'user signed up'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(and(equals(e.event, '$pageview'), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, '$current_url'), ''), 'null'), '^"|"$', ''), 'aloha.com'), 0)), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(and(equals(e.event, '$pageview'), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, '$current_url'), ''), 'null'), '^"|"$', ''), 'aloha2.com'), 0)), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2 - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS e__pdi___person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - LEFT JOIN - (SELECT person.id AS id, replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(person.properties, 'email'), ''), 'null'), '^"|"$', '') AS properties___email, replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(person.properties, 'age'), ''), 'null'), '^"|"$', '') AS properties___age - FROM person - WHERE and(equals(person.team_id, 2), ifNull(in(tuple(person.id, person.version), - (SELECT person.id AS id, max(person.version) AS version - FROM person - WHERE equals(person.team_id, 2) - GROUP BY person.id - HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)))), 0)) SETTINGS optimize_aggregation_in_order=1) AS e__pdi__person ON equals(e__pdi.e__pdi___person_id, e__pdi__person.id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2020-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2020-07-01 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('$pageview', 'user signed up')), or(and(ifNull(ilike(e__pdi__person.properties___email, '%.com%'), 0), ifNull(equals(e__pdi__person.properties___age, '20'), 0)), or(ifNull(ilike(e__pdi__person.properties___email, '%.org%'), 0), ifNull(equals(e__pdi__person.properties___age, '28'), 0)))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [1, 2, 3]), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.created_at DESC @@ -700,9 +618,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -811,50 +728,7 @@ (SELECT argMax(toTimeZone(person.created_at, 'UTC'), person.version) AS created_at, person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, latest_2 AS latest_2, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2 - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2 - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2 - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, if(equals(e.event, 'user signed up'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(and(equals(e.event, '$pageview'), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, '$current_url'), ''), 'null'), '^"|"$', ''), 'aloha.com'), 0)), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(and(equals(e.event, '$pageview'), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, '$current_url'), ''), 'null'), '^"|"$', ''), 'aloha2.com'), 0)), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2 - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS e__pdi___person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - LEFT JOIN - (SELECT person.id AS id, replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(person.properties, 'email'), ''), 'null'), '^"|"$', '') AS properties___email, replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(person.properties, 'age'), ''), 'null'), '^"|"$', '') AS properties___age - FROM person - WHERE and(equals(person.team_id, 2), ifNull(in(tuple(person.id, person.version), - (SELECT person.id AS id, max(person.version) AS version - FROM person - WHERE equals(person.team_id, 2) - GROUP BY person.id - HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)))), 0)) SETTINGS optimize_aggregation_in_order=1) AS e__pdi__person ON equals(e__pdi.e__pdi___person_id, e__pdi__person.id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2020-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2020-07-01 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('$pageview', 'user signed up')), or(and(ifNull(ilike(e__pdi__person.properties___email, '%.com%'), 0), ifNull(equals(e__pdi__person.properties___age, '20'), 0)), or(ifNull(ilike(e__pdi__person.properties___email, '%.org%'), 0), ifNull(equals(e__pdi__person.properties___age, '28'), 0)))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [2, 3]), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.created_at DESC @@ -863,9 +737,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -974,50 +847,7 @@ (SELECT argMax(toTimeZone(person.created_at, 'UTC'), person.version) AS created_at, person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, latest_2 AS latest_2, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2 - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2 - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2 - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, if(equals(e.event, 'user signed up'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(and(equals(e.event, '$pageview'), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, '$current_url'), ''), 'null'), '^"|"$', ''), 'aloha.com'), 0)), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(and(equals(e.event, '$pageview'), ifNull(equals(replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(e.properties, '$current_url'), ''), 'null'), '^"|"$', ''), 'aloha2.com'), 0)), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2 - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS e__pdi___person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - LEFT JOIN - (SELECT person.id AS id, replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(person.properties, 'email'), ''), 'null'), '^"|"$', '') AS properties___email, replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(person.properties, 'age'), ''), 'null'), '^"|"$', '') AS properties___age - FROM person - WHERE and(equals(person.team_id, 2), ifNull(in(tuple(person.id, person.version), - (SELECT person.id AS id, max(person.version) AS version - FROM person - WHERE equals(person.team_id, 2) - GROUP BY person.id - HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)))), 0)) SETTINGS optimize_aggregation_in_order=1) AS e__pdi__person ON equals(e__pdi.e__pdi___person_id, e__pdi__person.id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2020-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2020-07-01 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('$pageview', 'user signed up')), or(and(ifNull(ilike(e__pdi__person.properties___email, '%.com%'), 0), ifNull(equals(e__pdi__person.properties___age, '20'), 0)), or(ifNull(ilike(e__pdi__person.properties___email, '%.org%'), 0), ifNull(equals(e__pdi__person.properties___age, '28'), 0)))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [3]), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.created_at DESC @@ -1026,9 +856,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -1103,9 +932,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -1168,9 +996,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -1266,9 +1093,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -1371,9 +1197,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -1469,9 +1294,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -1608,9 +1432,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -1747,9 +1570,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -1893,9 +1715,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_breakdowns_by_current_url.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_breakdowns_by_current_url.ambr index 968e9f59ec233..b507403f6e484 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_breakdowns_by_current_url.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_breakdowns_by_current_url.ambr @@ -90,9 +90,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -188,9 +187,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_correlation.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_correlation.ambr index 404380346de1c..04a7ddc45281f 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_correlation.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_correlation.ambr @@ -147,9 +147,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -310,9 +309,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -489,9 +487,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -504,9 +501,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -683,9 +679,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -698,9 +693,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -877,9 +871,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -892,9 +885,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1071,9 +1063,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1086,9 +1077,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1249,9 +1239,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1428,9 +1417,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1443,9 +1431,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1622,9 +1609,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1637,9 +1623,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1816,9 +1801,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1831,9 +1815,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2010,9 +1993,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2025,9 +2007,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2164,9 +2145,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2303,9 +2283,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2436,9 +2415,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2552,9 +2530,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2668,9 +2645,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2784,9 +2760,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2900,9 +2875,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3049,9 +3023,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3165,9 +3138,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3281,9 +3253,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3414,9 +3385,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3530,9 +3500,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3646,9 +3615,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3762,9 +3730,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3878,9 +3845,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4027,9 +3993,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4143,9 +4108,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4259,9 +4223,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4407,9 +4370,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4530,9 +4492,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4653,9 +4614,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4776,9 +4736,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4899,9 +4858,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5047,9 +5005,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5195,9 +5152,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5318,9 +5274,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5441,9 +5396,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5564,9 +5518,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5687,9 +5640,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5835,9 +5787,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5983,9 +5934,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -6106,9 +6056,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -6229,9 +6178,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -6352,9 +6300,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -6475,9 +6422,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -6623,9 +6569,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -6771,9 +6716,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -6894,9 +6838,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -7017,9 +6960,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -7140,9 +7082,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -7263,9 +7204,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -7411,9 +7351,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -7559,9 +7498,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -7682,9 +7620,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -7805,9 +7742,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -7928,9 +7864,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -8051,9 +7986,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -8199,9 +8133,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_correlations_persons.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_correlations_persons.ambr index e939cd2b30bfa..687a7c05a8429 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_correlations_persons.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_correlations_persons.ambr @@ -167,9 +167,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -182,9 +181,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -434,9 +432,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -449,9 +446,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -628,9 +624,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -643,9 +638,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -822,9 +816,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -837,9 +830,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1016,9 +1008,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1031,9 +1022,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_persons.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_persons.ambr index 2044dcbed3b96..77fe0acf7118f 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_persons.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_persons.ambr @@ -157,50 +157,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, step_0_matching_events AS matching_events - FROM - (SELECT groupArray(10)(step_0_matching_event) AS step_0_matching_events, groupArray(10)(step_1_matching_event) AS step_1_matching_events, groupArray(10)(step_2_matching_event) AS step_2_matching_events, groupArray(10)(final_matching_event) AS final_matching_events, aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event, aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time, tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2, if(ifNull(less(latest_2, latest_1), 0), NULL, uuid_2) AS uuid_2, if(ifNull(less(latest_2, latest_1), 0), NULL, `$session_id_2`) AS `$session_id_2`, if(ifNull(less(latest_2, latest_1), 0), NULL, `$window_id_2`) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, last_value(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_1, last_value(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_1`, last_value(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-08 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [1, 2, 3]), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -209,9 +166,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -225,9 +181,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -389,50 +344,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, step_1_matching_events AS matching_events - FROM - (SELECT groupArray(10)(step_0_matching_event) AS step_0_matching_events, groupArray(10)(step_1_matching_event) AS step_1_matching_events, groupArray(10)(step_2_matching_event) AS step_2_matching_events, groupArray(10)(final_matching_event) AS final_matching_events, aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event, aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time, tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2, if(ifNull(less(latest_2, latest_1), 0), NULL, uuid_2) AS uuid_2, if(ifNull(less(latest_2, latest_1), 0), NULL, `$session_id_2`) AS `$session_id_2`, if(ifNull(less(latest_2, latest_1), 0), NULL, `$window_id_2`) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, last_value(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_1, last_value(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_1`, last_value(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-08 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [2, 3]), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -441,9 +353,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -457,9 +368,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -621,50 +531,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, step_1_matching_events AS matching_events - FROM - (SELECT groupArray(10)(step_0_matching_event) AS step_0_matching_events, groupArray(10)(step_1_matching_event) AS step_1_matching_events, groupArray(10)(step_2_matching_event) AS step_2_matching_events, groupArray(10)(final_matching_event) AS final_matching_events, aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event, aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time, tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2, if(ifNull(less(latest_2, latest_1), 0), NULL, uuid_2) AS uuid_2, if(ifNull(less(latest_2, latest_1), 0), NULL, `$session_id_2`) AS `$session_id_2`, if(ifNull(less(latest_2, latest_1), 0), NULL, `$window_id_2`) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, last_value(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_1, last_value(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_1`, last_value(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-08 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(equals(steps, 2), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -673,9 +540,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -689,9 +555,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_strict.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_strict.ambr index 453e2164d2150..7e7d0e0586b32 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_strict.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_strict.ambr @@ -89,9 +89,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -193,9 +192,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -290,9 +288,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -406,9 +403,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -522,9 +518,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -645,9 +640,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_strict_persons.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_strict_persons.ambr index ce3fa166cffc8..38a6cd3b37d4f 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_strict_persons.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_strict_persons.ambr @@ -117,42 +117,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, step_0_matching_events AS matching_events - FROM - (SELECT groupArray(10)(step_0_matching_event) AS step_0_matching_events, groupArray(10)(step_1_matching_event) AS step_1_matching_events, groupArray(10)(step_2_matching_event) AS step_2_matching_events, groupArray(10)(final_matching_event) AS final_matching_events, aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event, aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time, tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS latest_1, min(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS uuid_1, min(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS `$session_id_1`, min(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS latest_2, min(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS uuid_2, min(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS `$session_id_2`, min(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-08 23:59:59.999999', 6, 'UTC')))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [1, 2, 3]), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -161,9 +126,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -177,9 +141,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -301,42 +264,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, step_1_matching_events AS matching_events - FROM - (SELECT groupArray(10)(step_0_matching_event) AS step_0_matching_events, groupArray(10)(step_1_matching_event) AS step_1_matching_events, groupArray(10)(step_2_matching_event) AS step_2_matching_events, groupArray(10)(final_matching_event) AS final_matching_events, aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event, aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time, tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS latest_1, min(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS uuid_1, min(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS `$session_id_1`, min(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS latest_2, min(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS uuid_2, min(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS `$session_id_2`, min(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-08 23:59:59.999999', 6, 'UTC')))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [2, 3]), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -345,9 +273,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -361,9 +288,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -485,42 +411,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, step_1_matching_events AS matching_events - FROM - (SELECT groupArray(10)(step_0_matching_event) AS step_0_matching_events, groupArray(10)(step_1_matching_event) AS step_1_matching_events, groupArray(10)(step_2_matching_event) AS step_2_matching_events, groupArray(10)(final_matching_event) AS final_matching_events, aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event, aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time, tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS latest_1, min(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS uuid_1, min(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS `$session_id_1`, min(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 1 PRECEDING AND 1 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS latest_2, min(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS uuid_2, min(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS `$session_id_2`, min(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN 2 PRECEDING AND 2 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-08 23:59:59.999999', 6, 'UTC')))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(equals(steps, 2), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -529,9 +420,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -545,9 +435,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_time_to_convert.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_time_to_convert.ambr index 22a3489348248..1643acebc69ce 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_time_to_convert.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_time_to_convert.ambr @@ -413,9 +413,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -761,9 +760,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -1509,9 +1507,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_trends.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_trends.ambr index e02eb64d9a216..7267c85d00c1b 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_trends.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_trends.ambr @@ -85,9 +85,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -178,9 +177,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -271,9 +269,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_trends_persons.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_trends_persons.ambr index 5b7df2345a412..db29653790237 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_trends_persons.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_trends_persons.ambr @@ -143,47 +143,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, step_1_matching_events AS matching_events - FROM - (SELECT aggregation_target AS aggregation_target, toStartOfDay(timestamp) AS entrance_period_start, max(steps) AS steps_completed, groupArray(10)(step_0_matching_event) AS step_0_matching_events, groupArray(10)(step_1_matching_event) AS step_1_matching_events, groupArray(10)(step_2_matching_event) AS step_2_matching_events, groupArray(10)(final_matching_event) AS final_matching_events - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time, tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2, if(ifNull(less(latest_2, latest_1), 0), NULL, uuid_2) AS uuid_2, if(ifNull(less(latest_2, latest_1), 0), NULL, `$session_id_2`) AS `$session_id_2`, if(ifNull(less(latest_2, latest_1), 0), NULL, `$window_id_2`) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, last_value(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_1, last_value(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_1`, last_value(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-05-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-05-07 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0)) - WHERE ifNull(equals(entrance_period_start, toDateTime64('2021-05-01 00:00:00.000000', 6, 'UTC')), 0) - GROUP BY aggregation_target, entrance_period_start) - WHERE ifNull(greaterOrEquals(steps_completed, 2), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -192,9 +152,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -208,9 +167,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -358,47 +316,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, final_matching_events AS matching_events - FROM - (SELECT aggregation_target AS aggregation_target, toStartOfDay(timestamp) AS entrance_period_start, max(steps) AS steps_completed, groupArray(10)(step_0_matching_event) AS step_0_matching_events, groupArray(10)(step_1_matching_event) AS step_1_matching_events, groupArray(10)(step_2_matching_event) AS step_2_matching_events, groupArray(10)(final_matching_event) AS final_matching_events - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time, tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2, if(ifNull(less(latest_2, latest_1), 0), NULL, uuid_2) AS uuid_2, if(ifNull(less(latest_2, latest_1), 0), NULL, `$session_id_2`) AS `$session_id_2`, if(ifNull(less(latest_2, latest_1), 0), NULL, `$window_id_2`) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, last_value(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_1, last_value(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_1`, last_value(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-05-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-05-07 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0)) - WHERE ifNull(equals(entrance_period_start, toDateTime64('2021-05-01 00:00:00.000000', 6, 'UTC')), 0) - GROUP BY aggregation_target, entrance_period_start) - WHERE and(ifNull(greaterOrEquals(steps_completed, 1), 0), ifNull(less(steps_completed, 3), 0)) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -407,9 +325,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -423,9 +340,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -573,47 +489,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, final_matching_events AS matching_events - FROM - (SELECT aggregation_target AS aggregation_target, toStartOfDay(timestamp) AS entrance_period_start, max(steps) AS steps_completed, groupArray(10)(step_0_matching_event) AS step_0_matching_events, groupArray(10)(step_1_matching_event) AS step_1_matching_events, groupArray(10)(step_2_matching_event) AS step_2_matching_events, groupArray(10)(final_matching_event) AS final_matching_events - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0), ifNull(lessOrEquals(latest_1, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 3, if(and(ifNull(lessOrEquals(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1)) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time, if(and(isNotNull(latest_2), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_1, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_1, latest_2), NULL) AS step_2_conversion_time, tuple(latest_0, uuid_0, `$session_id_0`, `$window_id_0`) AS step_0_matching_event, tuple(latest_1, uuid_1, `$session_id_1`, `$window_id_1`) AS step_1_matching_event, tuple(latest_2, uuid_2, `$session_id_2`, `$window_id_2`) AS step_2_matching_event, if(isNull(latest_0), tuple(NULL, NULL, NULL, NULL), if(isNull(latest_1), step_0_matching_event, if(isNull(latest_2), step_1_matching_event, step_2_matching_event))) AS final_matching_event - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, if(ifNull(less(latest_2, latest_1), 0), NULL, latest_2) AS latest_2, if(ifNull(less(latest_2, latest_1), 0), NULL, uuid_2) AS uuid_2, if(ifNull(less(latest_2, latest_1), 0), NULL, `$session_id_2`) AS `$session_id_2`, if(ifNull(less(latest_2, latest_1), 0), NULL, `$window_id_2`) AS `$window_id_2` - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, last_value(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_1, last_value(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_1`, last_value(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-05-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-05-07 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))))) - WHERE ifNull(equals(step_0, 1), 0)) - WHERE ifNull(equals(entrance_period_start, toDateTime64('2021-05-01 00:00:00.000000', 6, 'UTC')), 0) - GROUP BY aggregation_target, entrance_period_start) - WHERE ifNull(greaterOrEquals(steps_completed, 3), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -622,9 +498,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' @@ -638,9 +513,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_unordered.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_unordered.ambr index 778829c29b4da..47d77c0817e46 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_unordered.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_unordered.ambr @@ -143,9 +143,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -308,9 +307,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -459,9 +457,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -705,9 +702,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -951,9 +947,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' @@ -1218,9 +1213,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128, allow_experimental_analyzer=1 ''' diff --git a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_unordered_persons.ambr b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_unordered_persons.ambr index b610dfb3f779d..65609c28ee890 100644 --- a/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_unordered_persons.ambr +++ b/posthog/hogql_queries/insights/funnels/test/__snapshots__/test_funnel_unordered_persons.ambr @@ -261,86 +261,7 @@ INNER JOIN (SELECT person.id AS id FROM person - WHERE and(equals(person.team_id, 2), in(id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id, array() AS matching_events - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, avg(step_2_conversion_time) AS step_2_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner, median(step_2_conversion_time) AS step_2_median_conversion_time_inner - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time, step_2_conversion_time AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, arraySort([latest_0, latest_1, latest_2]) AS event_times, arraySum([if(and(ifNull(less(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 1, 0), if(and(ifNull(less(latest_0, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 1, 0), 1]) AS steps, arraySort([latest_0, latest_1, latest_2]) AS conversion_times, if(and(isNotNull(conversion_times[2]), ifNull(lessOrEquals(conversion_times[2], plus(toTimeZone(conversion_times[1], 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', conversion_times[1], conversion_times[2]), NULL) AS step_1_conversion_time, if(and(isNotNull(conversion_times[3]), ifNull(lessOrEquals(conversion_times[3], plus(toTimeZone(conversion_times[2], 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', conversion_times[2], conversion_times[3]), NULL) AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, last_value(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_1, last_value(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_1`, last_value(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step one'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step two'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step three'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-08 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))) - WHERE ifNull(equals(step_0, 1), 0) - UNION ALL SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, arraySort([latest_0, latest_1, latest_2]) AS event_times, arraySum([if(and(ifNull(less(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 1, 0), if(and(ifNull(less(latest_0, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 1, 0), 1]) AS steps, arraySort([latest_0, latest_1, latest_2]) AS conversion_times, if(and(isNotNull(conversion_times[2]), ifNull(lessOrEquals(conversion_times[2], plus(toTimeZone(conversion_times[1], 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', conversion_times[1], conversion_times[2]), NULL) AS step_1_conversion_time, if(and(isNotNull(conversion_times[3]), ifNull(lessOrEquals(conversion_times[3], plus(toTimeZone(conversion_times[2], 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', conversion_times[2], conversion_times[3]), NULL) AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, last_value(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_1, last_value(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_1`, last_value(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step two'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step three'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step one'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-08 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))) - WHERE ifNull(equals(step_0, 1), 0) - UNION ALL SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, latest_1 AS latest_1, uuid_1 AS uuid_1, `$session_id_1` AS `$session_id_1`, `$window_id_1` AS `$window_id_1`, step_2 AS step_2, latest_2 AS latest_2, uuid_2 AS uuid_2, `$session_id_2` AS `$session_id_2`, `$window_id_2` AS `$window_id_2`, arraySort([latest_0, latest_1, latest_2]) AS event_times, arraySum([if(and(ifNull(less(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 1, 0), if(and(ifNull(less(latest_0, latest_2), 0), ifNull(lessOrEquals(latest_2, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 1, 0), 1]) AS steps, arraySort([latest_0, latest_1, latest_2]) AS conversion_times, if(and(isNotNull(conversion_times[2]), ifNull(lessOrEquals(conversion_times[2], plus(toTimeZone(conversion_times[1], 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', conversion_times[1], conversion_times[2]), NULL) AS step_1_conversion_time, if(and(isNotNull(conversion_times[3]), ifNull(lessOrEquals(conversion_times[3], plus(toTimeZone(conversion_times[2], 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', conversion_times[2], conversion_times[3]), NULL) AS step_2_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, uuid_0 AS uuid_0, `$session_id_0` AS `$session_id_0`, `$window_id_0` AS `$window_id_0`, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_1, last_value(uuid_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_1, last_value(`$session_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_1`, last_value(`$window_id_1`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_1`, step_2 AS step_2, min(latest_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS latest_2, last_value(uuid_2) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS uuid_2, last_value(`$session_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$session_id_2`, last_value(`$window_id_2`) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 0 PRECEDING) AS `$window_id_2` - FROM - (SELECT toTimeZone(e.timestamp, 'UTC') AS timestamp, e__pdi.person_id AS aggregation_target, e.uuid AS uuid, if(equals(e.event, 'step three'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(ifNull(equals(step_0, 1), 0), uuid, NULL) AS uuid_0, if(ifNull(equals(step_0, 1), 0), e.`$session_id`, NULL) AS `$session_id_0`, if(ifNull(equals(step_0, 1), 0), e.`$window_id`, NULL) AS `$window_id_0`, if(equals(e.event, 'step one'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1, if(ifNull(equals(step_1, 1), 0), uuid, NULL) AS uuid_1, if(ifNull(equals(step_1, 1), 0), e.`$session_id`, NULL) AS `$session_id_1`, if(ifNull(equals(step_1, 1), 0), e.`$window_id`, NULL) AS `$window_id_1`, if(equals(e.event, 'step two'), 1, 0) AS step_2, if(ifNull(equals(step_2, 1), 0), timestamp, NULL) AS latest_2, if(ifNull(equals(step_2, 1), 0), uuid, NULL) AS uuid_2, if(ifNull(equals(step_2, 1), 0), e.`$session_id`, NULL) AS `$session_id_2`, if(ifNull(equals(step_2, 1), 0), e.`$window_id`, NULL) AS `$window_id_2` - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-01 00:00:00.000000', 6, 'UTC')), lessOrEquals(toTimeZone(e.timestamp, 'UTC'), toDateTime64('2021-01-08 23:59:59.999999', 6, 'UTC'))), in(e.event, tuple('step one', 'step three', 'step two'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0), ifNull(equals(step_2, 1), 0))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [1, 2, 3]), 0) - ORDER BY aggregation_target ASC) AS source))) + WHERE equals(person.team_id, 2) GROUP BY person.id HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'UTC'), person.version), plus(now64(6, 'UTC'), toIntervalDay(1))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.id ASC @@ -349,9 +270,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0, allow_experimental_analyzer=1 ''' diff --git a/posthog/hogql_queries/insights/test/__snapshots__/test_insight_actors_query_runner.ambr b/posthog/hogql_queries/insights/test/__snapshots__/test_insight_actors_query_runner.ambr index 7da32ae06082c..052afc663b683 100644 --- a/posthog/hogql_queries/insights/test/__snapshots__/test_insight_actors_query_runner.ambr +++ b/posthog/hogql_queries/insights/test/__snapshots__/test_insight_actors_query_runner.ambr @@ -60,48 +60,19 @@ (SELECT person.id AS id, replaceRegexpAll(nullIf(nullIf(JSONExtractRaw(person.properties, 'name'), ''), 'null'), '^"|"$', '') AS properties___name FROM person - WHERE and(equals(person.team_id, 2), in(tuple(person.id, person.version), - (SELECT person.id AS id, max(person.version) AS version - FROM person - WHERE and(equals(person.team_id, 2), in(person.id, - (SELECT source.actor_id AS actor_id - FROM - (SELECT aggregation_target AS actor_id - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, avg(step_1_conversion_time) AS step_1_average_conversion_time_inner, median(step_1_conversion_time) AS step_1_median_conversion_time_inner - FROM - (SELECT aggregation_target AS aggregation_target, steps AS steps, max(steps) OVER (PARTITION BY aggregation_target) AS max_steps, step_1_conversion_time AS step_1_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, latest_1 AS latest_1, if(and(ifNull(less(latest_0, latest_1), 0), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), 2, 1) AS steps, if(and(isNotNull(latest_1), ifNull(lessOrEquals(latest_1, plus(toTimeZone(latest_0, 'UTC'), toIntervalDay(14))), 0)), dateDiff('second', latest_0, latest_1), NULL) AS step_1_conversion_time - FROM - (SELECT aggregation_target AS aggregation_target, timestamp AS timestamp, step_0 AS step_0, latest_0 AS latest_0, step_1 AS step_1, min(latest_1) OVER (PARTITION BY aggregation_target - ORDER BY timestamp DESC ROWS BETWEEN UNBOUNDED PRECEDING AND 1 PRECEDING) AS latest_1 - FROM - (SELECT toTimeZone(e.timestamp, 'US/Pacific') AS timestamp, e__pdi.person_id AS aggregation_target, if(equals(e.event, '$pageview'), 1, 0) AS step_0, if(ifNull(equals(step_0, 1), 0), timestamp, NULL) AS latest_0, if(equals(e.event, '$pageview'), 1, 0) AS step_1, if(ifNull(equals(step_1, 1), 0), timestamp, NULL) AS latest_1 - FROM events AS e - INNER JOIN - (SELECT argMax(person_distinct_id2.person_id, person_distinct_id2.version) AS person_id, person_distinct_id2.distinct_id AS distinct_id - FROM person_distinct_id2 - WHERE equals(person_distinct_id2.team_id, 2) - GROUP BY person_distinct_id2.distinct_id - HAVING ifNull(equals(argMax(person_distinct_id2.is_deleted, person_distinct_id2.version), 0), 0) SETTINGS optimize_aggregation_in_order=1) AS e__pdi ON equals(e.distinct_id, e__pdi.distinct_id) - WHERE and(equals(e.team_id, 2), and(and(greaterOrEquals(toTimeZone(e.timestamp, 'US/Pacific'), toDateTime64('2020-01-01 00:00:00.000000', 6, 'US/Pacific')), lessOrEquals(toTimeZone(e.timestamp, 'US/Pacific'), toDateTime64('2020-01-19 23:59:59.999999', 6, 'US/Pacific'))), in(e.event, tuple('$pageview'))), or(ifNull(equals(step_0, 1), 0), ifNull(equals(step_1, 1), 0))))) - WHERE ifNull(equals(step_0, 1), 0))) - GROUP BY aggregation_target, steps - HAVING ifNull(equals(steps, max(max_steps)), isNull(steps) - and isNull(max(max_steps)))) - WHERE ifNull(in(steps, [2]), 0) - ORDER BY aggregation_target ASC) AS source))) - GROUP BY person.id - HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'US/Pacific'), person.version), plus(now64(6, 'US/Pacific'), toIntervalDay(1))), 0))))) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) + WHERE and(equals(person.team_id, 2), ifNull(in(tuple(person.id, person.version), + (SELECT person.id AS id, max(person.version) AS version + FROM person + WHERE equals(person.team_id, 2) + GROUP BY person.id + HAVING and(ifNull(equals(argMax(person.is_deleted, person.version), 0), 0), ifNull(less(argMax(toTimeZone(person.created_at, 'US/Pacific'), person.version), plus(now64(6, 'US/Pacific'), toIntervalDay(1))), 0)))), 0)) SETTINGS optimize_aggregation_in_order=1) AS persons ON equals(persons.id, source.actor_id) ORDER BY persons.properties___name ASC) LIMIT 100 SETTINGS readonly=2, max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -189,9 +160,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -222,9 +192,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -279,9 +248,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -313,9 +281,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -381,9 +348,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -458,9 +424,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/insights/test/__snapshots__/test_lifecycle_query_runner.ambr b/posthog/hogql_queries/insights/test/__snapshots__/test_lifecycle_query_runner.ambr index 0bd87128f34ad..24b6d55a4c7ce 100644 --- a/posthog/hogql_queries/insights/test/__snapshots__/test_lifecycle_query_runner.ambr +++ b/posthog/hogql_queries/insights/test/__snapshots__/test_lifecycle_query_runner.ambr @@ -93,9 +93,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -170,9 +169,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -247,9 +245,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -324,9 +321,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/insights/test/__snapshots__/test_paths_query_runner_ee.ambr b/posthog/hogql_queries/insights/test/__snapshots__/test_paths_query_runner_ee.ambr index 116dc151cba73..d4975a5c677b7 100644 --- a/posthog/hogql_queries/insights/test/__snapshots__/test_paths_query_runner_ee.ambr +++ b/posthog/hogql_queries/insights/test/__snapshots__/test_paths_query_runner_ee.ambr @@ -77,9 +77,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -161,9 +160,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -245,9 +243,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -329,9 +326,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -412,9 +408,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -495,9 +490,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -578,9 +572,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -661,9 +654,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -744,9 +736,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -827,9 +818,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -910,9 +900,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -1001,9 +990,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -1085,9 +1073,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -1169,9 +1156,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -1319,9 +1305,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1467,9 +1452,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1615,9 +1599,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1765,9 +1748,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1913,9 +1895,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2061,9 +2042,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2211,9 +2191,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2359,9 +2338,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2507,9 +2485,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2599,9 +2576,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -2751,9 +2727,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2766,9 +2741,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2920,9 +2894,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3074,9 +3047,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3089,9 +3061,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3241,9 +3212,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3256,9 +3226,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3418,9 +3387,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3433,9 +3401,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3516,9 +3483,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -3604,9 +3570,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -3762,9 +3727,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3850,9 +3814,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -4008,9 +3971,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4096,9 +4058,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -4254,9 +4215,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4342,9 +4302,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -4500,9 +4459,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4584,9 +4542,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -4667,9 +4624,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -4750,9 +4706,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -4898,9 +4853,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5046,9 +5000,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5129,9 +5082,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -5277,9 +5229,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5360,9 +5311,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -5508,9 +5458,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5656,9 +5605,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5804,9 +5752,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5887,9 +5834,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -5975,9 +5921,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- diff --git a/posthog/hogql_queries/insights/test/__snapshots__/test_retention_query_runner.ambr b/posthog/hogql_queries/insights/test/__snapshots__/test_retention_query_runner.ambr index 518a99bc726f3..f4d2059bf0fff 100644 --- a/posthog/hogql_queries/insights/test/__snapshots__/test_retention_query_runner.ambr +++ b/posthog/hogql_queries/insights/test/__snapshots__/test_retention_query_runner.ambr @@ -22,9 +22,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -68,9 +67,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -97,9 +95,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -126,9 +123,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -172,9 +168,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -201,9 +196,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -237,9 +231,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -282,9 +275,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -318,9 +310,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -365,9 +356,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -401,9 +391,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -437,9 +426,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -473,9 +461,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- @@ -509,9 +496,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=23622320128 ''' # --- diff --git a/posthog/hogql_queries/insights/trends/test/__snapshots__/test_trends.ambr b/posthog/hogql_queries/insights/trends/test/__snapshots__/test_trends.ambr index a30c0d235550c..e6896e9910b67 100644 --- a/posthog/hogql_queries/insights/trends/test/__snapshots__/test_trends.ambr +++ b/posthog/hogql_queries/insights/trends/test/__snapshots__/test_trends.ambr @@ -91,9 +91,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -178,9 +177,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -227,9 +225,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -286,9 +283,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -301,9 +297,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -350,9 +345,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -391,9 +385,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -432,9 +425,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -473,9 +465,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -514,9 +505,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -575,9 +565,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -636,9 +625,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -734,9 +722,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -783,9 +770,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -848,9 +834,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -896,9 +881,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -944,9 +928,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -992,9 +975,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1040,9 +1022,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1125,9 +1106,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1192,9 +1172,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1235,9 +1214,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1307,9 +1285,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1322,9 +1299,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1357,9 +1333,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1433,9 +1408,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1509,9 +1483,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1573,9 +1546,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1637,9 +1609,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1664,9 +1635,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1735,9 +1705,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1806,9 +1775,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1851,9 +1819,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1896,9 +1863,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1923,9 +1889,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1968,9 +1933,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1995,9 +1959,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2040,9 +2003,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2076,9 +2038,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2110,9 +2071,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2153,9 +2113,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2196,9 +2155,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2239,9 +2197,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2266,9 +2223,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2300,9 +2256,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2347,9 +2302,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2374,9 +2328,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2422,9 +2375,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2449,9 +2401,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2483,9 +2434,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2530,9 +2480,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2557,9 +2506,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2605,9 +2553,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2632,9 +2579,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2666,9 +2612,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2713,9 +2658,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2740,9 +2684,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2788,9 +2731,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2822,9 +2764,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2849,9 +2790,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2883,9 +2823,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2910,9 +2849,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2944,9 +2882,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2971,9 +2908,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2998,9 +2934,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3025,9 +2960,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3052,9 +2986,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3079,9 +3012,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3106,9 +3038,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3133,9 +3064,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3194,9 +3124,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3255,9 +3184,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3282,9 +3210,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3327,9 +3254,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3386,9 +3312,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3445,9 +3370,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3485,9 +3409,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3525,9 +3448,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3566,9 +3488,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3593,9 +3514,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3620,9 +3540,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3674,9 +3593,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3728,9 +3646,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3784,9 +3701,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3831,9 +3747,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3878,9 +3793,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3925,9 +3839,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3972,9 +3885,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3999,9 +3911,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4026,9 +3937,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4053,9 +3963,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4080,9 +3989,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4107,9 +4015,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4157,9 +4064,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4199,9 +4105,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4241,9 +4146,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4268,9 +4172,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4300,9 +4203,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4332,9 +4234,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4371,9 +4272,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4436,9 +4336,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4501,9 +4400,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4528,9 +4426,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4554,9 +4451,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4580,9 +4476,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4620,9 +4515,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4660,9 +4554,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4716,9 +4609,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4772,9 +4664,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4828,9 +4719,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4884,9 +4774,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4921,9 +4810,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4958,9 +4846,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4995,9 +4882,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5042,9 +4928,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5089,9 +4974,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5136,9 +5020,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5194,9 +5077,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5252,9 +5134,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5299,9 +5180,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5346,9 +5226,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5393,9 +5272,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -5440,9 +5318,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/insights/trends/test/__snapshots__/test_trends_data_warehouse_query.ambr b/posthog/hogql_queries/insights/trends/test/__snapshots__/test_trends_data_warehouse_query.ambr index 0912ca865eb33..e7519a92714c5 100644 --- a/posthog/hogql_queries/insights/trends/test/__snapshots__/test_trends_data_warehouse_query.ambr +++ b/posthog/hogql_queries/insights/trends/test/__snapshots__/test_trends_data_warehouse_query.ambr @@ -34,9 +34,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -75,9 +74,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -102,9 +100,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -129,9 +126,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -156,9 +152,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/test/__snapshots__/test_error_tracking_query_runner.ambr b/posthog/hogql_queries/test/__snapshots__/test_error_tracking_query_runner.ambr index 5063b17d2a1c5..25ad854463e1e 100644 --- a/posthog/hogql_queries/test/__snapshots__/test_error_tracking_query_runner.ambr +++ b/posthog/hogql_queries/test/__snapshots__/test_error_tracking_query_runner.ambr @@ -35,9 +35,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -75,9 +74,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -116,9 +114,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -138,9 +135,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -180,9 +176,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -221,9 +216,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/hogql_queries/test/__snapshots__/test_sessions_timeline_query_runner.ambr b/posthog/hogql_queries/test/__snapshots__/test_sessions_timeline_query_runner.ambr index 6a28ce7a3239e..6c80fa6a98319 100644 --- a/posthog/hogql_queries/test/__snapshots__/test_sessions_timeline_query_runner.ambr +++ b/posthog/hogql_queries/test/__snapshots__/test_sessions_timeline_query_runner.ambr @@ -62,9 +62,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -131,9 +130,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -200,9 +198,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -269,9 +266,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -338,9 +334,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -407,9 +402,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -476,9 +470,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- diff --git a/posthog/session_recordings/queries/test/__snapshots__/test_session_recording_list_from_filters.ambr b/posthog/session_recordings/queries/test/__snapshots__/test_session_recording_list_from_filters.ambr index 80de66af059de..efdf25db926cb 100644 --- a/posthog/session_recordings/queries/test/__snapshots__/test_session_recording_list_from_filters.ambr +++ b/posthog/session_recordings/queries/test/__snapshots__/test_session_recording_list_from_filters.ambr @@ -31,9 +31,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -69,9 +68,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -107,9 +105,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -145,9 +142,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -191,9 +187,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -229,9 +224,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -267,9 +261,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -305,9 +298,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -343,9 +335,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -381,9 +372,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -419,9 +409,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -452,9 +441,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -485,9 +473,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -518,9 +505,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -551,9 +537,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -584,9 +569,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -617,9 +601,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -650,9 +633,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -683,9 +665,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -716,9 +697,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -749,9 +729,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -782,9 +761,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -815,9 +793,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -848,9 +825,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -881,9 +857,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -914,9 +889,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -947,9 +921,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -980,9 +953,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1013,9 +985,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1046,9 +1017,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1084,9 +1054,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1122,9 +1091,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1160,9 +1128,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1193,9 +1160,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1231,9 +1197,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1269,9 +1234,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1312,9 +1276,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1350,9 +1313,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1420,9 +1382,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1490,9 +1451,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1528,9 +1488,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1598,9 +1557,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1668,9 +1626,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1721,9 +1678,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1774,9 +1730,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1812,9 +1767,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1850,9 +1804,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1888,9 +1841,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1926,9 +1878,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -1964,9 +1915,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2002,9 +1952,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2040,9 +1989,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2078,9 +2026,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2116,9 +2063,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2154,9 +2100,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2192,9 +2137,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2230,9 +2174,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2268,9 +2211,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2306,9 +2248,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2376,9 +2317,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2414,9 +2354,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2484,9 +2423,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2522,9 +2460,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2560,9 +2497,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2599,9 +2535,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2638,9 +2573,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2677,9 +2611,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2716,9 +2649,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2749,9 +2681,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2782,9 +2713,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2821,9 +2751,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2860,9 +2789,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2899,9 +2827,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2938,9 +2865,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -2977,9 +2903,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3016,9 +2941,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3055,9 +2979,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3094,9 +3017,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3132,9 +3054,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3170,9 +3091,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3233,9 +3153,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3301,9 +3220,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3349,9 +3267,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3399,9 +3316,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3449,9 +3365,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3487,9 +3402,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3525,9 +3439,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3563,9 +3476,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3601,9 +3513,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3640,9 +3551,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3679,9 +3589,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3725,9 +3634,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3771,9 +3679,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3809,9 +3716,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3847,9 +3753,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3897,9 +3802,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3947,9 +3851,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -3988,9 +3891,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4026,9 +3928,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4064,9 +3965,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4102,9 +4002,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4140,9 +4039,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4178,9 +4076,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4216,9 +4113,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4254,9 +4150,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4292,9 +4187,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4330,9 +4224,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4368,9 +4261,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4406,9 +4298,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4444,9 +4335,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4482,9 +4372,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4532,9 +4421,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4570,9 +4458,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4620,9 +4507,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4658,9 +4544,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4708,9 +4593,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4746,9 +4630,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # --- @@ -4796,9 +4679,8 @@ max_execution_time=60, allow_experimental_object_type=1, format_csv_allow_double_quotes=0, - max_ast_elements=2000000, - max_expanded_ast_elements=2000000, - max_query_size=1048576, + max_ast_elements=4000000, + max_expanded_ast_elements=4000000, max_bytes_before_external_group_by=0 ''' # ---