\unset ECHO clickhouse_raw_query ---------------------- (1 row) clickhouse_raw_query ---------------------- (1 row) clickhouse_raw_query ---------------------- (1 row) clickhouse_raw_query ---------------------- (1 row) Foreign table "agg_bin.hits" Column | Type | Collation | Nullable | Default | FDW options -----------+-----------------------------+-----------+----------+---------+------------- id | bigint | | not null | | uuid | uuid | | not null | | timestamp | timestamp without time zone | | not null | | datestamp | date | | not null | | path | text | | not null | | duration | bigint | | not null | | cost | numeric(10,2) | | not null | | Server: agg_bin_svr FDW options: (database 'agg_test', table_name 'hits', engine 'MergeTree') Foreign table "agg_http.hits" Column | Type | Collation | Nullable | Default | FDW options -----------+-----------------------------+-----------+----------+---------+------------- id | bigint | | not null | | uuid | uuid | | not null | | timestamp | timestamp without time zone | | not null | | datestamp | date | | not null | | path | text | | not null | | duration | bigint | | not null | | cost | numeric(10,2) | | not null | | Server: agg_http_svr FDW options: (database 'agg_test', table_name 'hits', engine 'MergeTree') -- AVG(UInt64) QUERY PLAN ------------------------------------------------- Foreign Scan Output: (avg(id)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(id) FROM agg_test.hits (4 rows) avg --------------- 2420827679.54 (1 row) QUERY PLAN ------------------------------------------------- Foreign Scan Output: (avg(id)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(id) FROM agg_test.hits (4 rows) avg --------------- 2420827679.54 (1 row) QUERY PLAN --------------------------------------------------------------------------- Foreign Scan Output: (avg(id)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(id) FROM agg_test.hits WHERE ((id < 1000000000)) (4 rows) avg ------------- 404449748.2 (1 row) QUERY PLAN --------------------------------------------------------------------------- Foreign Scan Output: (avg(id)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(id) FROM agg_test.hits WHERE ((id < 1000000000)) (4 rows) avg ------------- 404449748.2 (1 row) -- AVG(UInt32) QUERY PLAN ------------------------------------------------------- Foreign Scan Output: (avg(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(duration) FROM agg_test.hits (4 rows) avg ------ 1095 (1 row) QUERY PLAN ------------------------------------------------------- Foreign Scan Output: (avg(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(duration) FROM agg_test.hits (4 rows) avg ------ 1095 (1 row) QUERY PLAN --------------------------------------------------------------------------------------- Foreign Scan Output: (avg(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(duration) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) avg ------ 1095 (1 row) QUERY PLAN --------------------------------------------------------------------------------------- Foreign Scan Output: (avg(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(duration) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) avg ------ 1095 (1 row) -- AVG(Decimal) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (avg(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(cost) FROM agg_test.hits (4 rows) avg -------- 5.0768 (1 row) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (avg(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(cost) FROM agg_test.hits (4 rows) avg -------- 5.0768 (1 row) QUERY PLAN ------------------------------------------------------------------------------- Foreign Scan Output: (avg(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(cost) FROM agg_test.hits WHERE ((cost < 1000000000)) (4 rows) avg -------- 5.0768 (1 row) QUERY PLAN ------------------------------------------------------------------------------- Foreign Scan Output: (avg(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT avg(cost) FROM agg_test.hits WHERE ((cost < 1000000000)) (4 rows) avg -------- 5.0768 (1 row) -- array_agg(UInt64) QUERY PLAN -------------------------------------------------------- Foreign Scan Output: (array_agg(id)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(id) FROM agg_test.hits (4 rows) array_agg -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {3498231651,1431223188,1331538905,3451631267,2757160710,4049681990,3319320102,2178896781,2433222225,3948091185,3122655508,3095867833,2720322600,2400403412,3159416553,4160213552,3910581405,3267604082,3841934465,4264738908,2005666276,3824162205,352088655,467263982,2890629064,4072815052,1008605146,837437371,3517179953,2836779925,1470995555,3849384968,3334361077,3258018379,1750004811,280308092,3231552675,392385086,287518381,1334989359,4093728327,1406653594,366963527,3432633864,104048445,914876110,1982637736,41607833,3814959307,1538392900} (1 row) QUERY PLAN -------------------------------------------------------- Foreign Scan Output: (array_agg(id)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(id) FROM agg_test.hits (4 rows) array_agg -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {3498231651,1431223188,1331538905,3451631267,2757160710,4049681990,3319320102,2178896781,2433222225,3948091185,3122655508,3095867833,2720322600,2400403412,3159416553,4160213552,3910581405,3267604082,3841934465,4264738908,2005666276,3824162205,352088655,467263982,2890629064,4072815052,1008605146,837437371,3517179953,2836779925,1470995555,3849384968,3334361077,3258018379,1750004811,280308092,3231552675,392385086,287518381,1334989359,4093728327,1406653594,366963527,3432633864,104048445,914876110,1982637736,41607833,3814959307,1538392900} (1 row) QUERY PLAN ---------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg(id)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(id) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ------------------------------------------------------------------------------------------------------ {352088655,467263982,837437371,280308092,392385086,287518381,366963527,104048445,914876110,41607833} (1 row) QUERY PLAN ---------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg(id)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(id) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ------------------------------------------------------------------------------------------------------ {352088655,467263982,837437371,280308092,392385086,287518381,366963527,104048445,914876110,41607833} (1 row) -- array_agg(UUID) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (array_agg(uuid)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(uuid) FROM agg_test.hits (4 rows) array_agg ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {8cab5a51-8927-43f4-8104-b2c81ffc3d8a,691a0477-c3fa-404d-a478-d4caaaa24832,f44459f2-9bbd-4149-9ac8-69c7b22f1aa0,148181e2-a573-481f-9e2a-02441d523034,974f2e1d-6918-4cce-935c-d445428584cc,720ad53d-db83-4091-a262-cfc7347f96ae,b623608d-459d-43d2-90ac-d1a8de83ff17,d205ee5d-dd47-4a63-be2f-198fcfb7403b,1f1dd4dd-2b05-4876-b98c-cb5ba1f34b89,a77b5881-262a-47c4-8494-a211e48b9c6c,aef92b53-0b2a-4777-8d9d-ce5a6443ef54,99f9a13a-357a-40fd-b415-1966865468d3,5c740ee9-a7a2-43e4-8ab1-e8c147f78c8b,d12fe0f1-9c4c-4039-9027-3e9f62d1da54,7885ab07-3740-461f-ac0c-c8732c07d86e,031a4434-e4f8-465d-8b13-7537ad578e93,1c0f3511-3f88-4d4a-a053-724449619420,d60a7c1d-dccf-427b-b685-9a6077a88867,c066fdd6-0172-46aa-9792-63455cb069b4,9f420aa6-f015-4caa-a2f8-2ca0e7a652a6,b8615e95-f95f-458e-aa87-b6e6634503d9,06fa959e-afe3-414d-9771-650547091079,f5468669-4391-4ed7-99be-82061f8f3f93,77af0ea8-2fef-4a21-bee0-335f9aa995c6,368679e8-8f2a-47dd-8bce-b491bdd09720,90b90c80-8f8e-44e1-9468-e4d2cddd22bb,6da3afd4-4fa3-49b7-ab29-ffe1b2bb7082,b5628648-e429-4fb9-9d77-de539d32f29f,3e4b5d8b-7b09-4d1c-9eb4-855f0ae108d2,5e57a6fe-0196-4100-865a-7d6dc55765c2,0d8c0e39-679f-4034-b48f-aa1595b02dfc,533582ce-95eb-4fb6-804e-6256ea6adaac,a04b2cbd-c5b9-4f65-8449-0827d6c7f712,d5c34dc5-b5db-455d-9528-fe466bdadd2c,eda72c6e-3161-47dd-ba25-cf059bb995da,68b5127e-9819-453f-812d-f1b90979f872,4886ebda-a378-4181-a291-c235ec1047a8,69229156-bb5a-450d-91a0-474f39a20bab,1adf4190-5147-4e7e-b354-7715a5a81c40,52220ad9-02f0-4ad7-ad74-dc6add362a99,44cccdf8-d398-40c7-9e41-117a37e93b9e,e636df93-8421-4926-bf6f-1d1ee36edd35,af62cc2f-e706-4d1d-a740-fd80c55a1250,b50622a5-0e0a-4f66-8be1-84c7cc6851b6,19b74725-9827-4d84-b4dc-b86788193002,2ddfb5b7-9ae5-428b-9351-48e823230672,969e2c53-c735-4649-a6a3-3107ed089cb0,ad89a796-f7c6-4549-bd2e-ced0e586a5a5,70525fca-b870-4976-9377-fc959353302a,7e3f2fe1-5312-4257-ba3e-54662ba14b56} (1 row) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (array_agg(uuid)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(uuid) FROM agg_test.hits (4 rows) array_agg ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {8cab5a51-8927-43f4-8104-b2c81ffc3d8a,691a0477-c3fa-404d-a478-d4caaaa24832,f44459f2-9bbd-4149-9ac8-69c7b22f1aa0,148181e2-a573-481f-9e2a-02441d523034,974f2e1d-6918-4cce-935c-d445428584cc,720ad53d-db83-4091-a262-cfc7347f96ae,b623608d-459d-43d2-90ac-d1a8de83ff17,d205ee5d-dd47-4a63-be2f-198fcfb7403b,1f1dd4dd-2b05-4876-b98c-cb5ba1f34b89,a77b5881-262a-47c4-8494-a211e48b9c6c,aef92b53-0b2a-4777-8d9d-ce5a6443ef54,99f9a13a-357a-40fd-b415-1966865468d3,5c740ee9-a7a2-43e4-8ab1-e8c147f78c8b,d12fe0f1-9c4c-4039-9027-3e9f62d1da54,7885ab07-3740-461f-ac0c-c8732c07d86e,031a4434-e4f8-465d-8b13-7537ad578e93,1c0f3511-3f88-4d4a-a053-724449619420,d60a7c1d-dccf-427b-b685-9a6077a88867,c066fdd6-0172-46aa-9792-63455cb069b4,9f420aa6-f015-4caa-a2f8-2ca0e7a652a6,b8615e95-f95f-458e-aa87-b6e6634503d9,06fa959e-afe3-414d-9771-650547091079,f5468669-4391-4ed7-99be-82061f8f3f93,77af0ea8-2fef-4a21-bee0-335f9aa995c6,368679e8-8f2a-47dd-8bce-b491bdd09720,90b90c80-8f8e-44e1-9468-e4d2cddd22bb,6da3afd4-4fa3-49b7-ab29-ffe1b2bb7082,b5628648-e429-4fb9-9d77-de539d32f29f,3e4b5d8b-7b09-4d1c-9eb4-855f0ae108d2,5e57a6fe-0196-4100-865a-7d6dc55765c2,0d8c0e39-679f-4034-b48f-aa1595b02dfc,533582ce-95eb-4fb6-804e-6256ea6adaac,a04b2cbd-c5b9-4f65-8449-0827d6c7f712,d5c34dc5-b5db-455d-9528-fe466bdadd2c,eda72c6e-3161-47dd-ba25-cf059bb995da,68b5127e-9819-453f-812d-f1b90979f872,4886ebda-a378-4181-a291-c235ec1047a8,69229156-bb5a-450d-91a0-474f39a20bab,1adf4190-5147-4e7e-b354-7715a5a81c40,52220ad9-02f0-4ad7-ad74-dc6add362a99,44cccdf8-d398-40c7-9e41-117a37e93b9e,e636df93-8421-4926-bf6f-1d1ee36edd35,af62cc2f-e706-4d1d-a740-fd80c55a1250,b50622a5-0e0a-4f66-8be1-84c7cc6851b6,19b74725-9827-4d84-b4dc-b86788193002,2ddfb5b7-9ae5-428b-9351-48e823230672,969e2c53-c735-4649-a6a3-3107ed089cb0,ad89a796-f7c6-4549-bd2e-ced0e586a5a5,70525fca-b870-4976-9377-fc959353302a,7e3f2fe1-5312-4257-ba3e-54662ba14b56} (1 row) QUERY PLAN ------------------------------------------------------------------------------------------ Foreign Scan Output: (array_agg(uuid)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(uuid) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {f5468669-4391-4ed7-99be-82061f8f3f93,77af0ea8-2fef-4a21-bee0-335f9aa995c6,b5628648-e429-4fb9-9d77-de539d32f29f,68b5127e-9819-453f-812d-f1b90979f872,69229156-bb5a-450d-91a0-474f39a20bab,1adf4190-5147-4e7e-b354-7715a5a81c40,af62cc2f-e706-4d1d-a740-fd80c55a1250,19b74725-9827-4d84-b4dc-b86788193002,2ddfb5b7-9ae5-428b-9351-48e823230672,ad89a796-f7c6-4549-bd2e-ced0e586a5a5} (1 row) QUERY PLAN ------------------------------------------------------------------------------------------ Foreign Scan Output: (array_agg(uuid)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(uuid) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {f5468669-4391-4ed7-99be-82061f8f3f93,77af0ea8-2fef-4a21-bee0-335f9aa995c6,b5628648-e429-4fb9-9d77-de539d32f29f,68b5127e-9819-453f-812d-f1b90979f872,69229156-bb5a-450d-91a0-474f39a20bab,1adf4190-5147-4e7e-b354-7715a5a81c40,af62cc2f-e706-4d1d-a740-fd80c55a1250,19b74725-9827-4d84-b4dc-b86788193002,2ddfb5b7-9ae5-428b-9351-48e823230672,ad89a796-f7c6-4549-bd2e-ced0e586a5a5} (1 row) -- array_agg(DateTime64) QUERY PLAN ----------------------------------------------------------------- Foreign Scan Output: (array_agg("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray("timestamp") FROM agg_test.hits (4 rows) array_agg ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ {"2025-12-05 11:51:04.390884","2025-12-05 12:22:20.135213","2025-12-05 14:31:50.452533","2025-12-05 19:06:00.126014","2025-12-05 19:07:10.399278","2025-12-05 20:07:22.673831","2025-12-06 03:25:34.627161","2025-12-06 05:50:56.818572","2025-12-06 13:02:50.972837","2025-12-07 15:42:06.88149","2025-12-07 17:28:58.124117","2025-12-07 23:20:36.618385","2025-12-08 01:59:58.417052","2025-12-08 03:00:24.806643","2025-12-08 14:42:58.34422","2025-12-08 20:14:32.23635","2025-12-09 00:08:20.392948","2025-12-10 00:39:44.518284","2025-12-10 00:49:32.950914","2025-12-10 04:57:48.584719","2025-12-10 09:29:52.666577","2025-12-10 13:40:28.486178","2025-12-10 16:24:16.877779","2025-12-12 09:52:04.236867","2025-12-12 20:46:06.572602","2025-12-12 23:50:54.686406","2025-12-13 06:58:08.868876","2025-12-13 10:27:26.390655","2025-12-13 14:15:10.219085","2025-12-13 14:54:36.17439","2025-12-13 17:08:04.502729","2025-12-13 18:05:14.46441","2025-12-13 21:09:06.290341","2025-12-14 11:21:28.869821","2025-12-14 17:21:16.478761","2025-12-14 22:32:04.449588","2025-12-15 07:35:16.55788","2025-12-15 16:41:30.608217","2025-12-15 17:07:24.893024","2025-12-15 18:34:26.171566","2025-12-15 21:17:32.577173","2025-12-16 09:13:10.107266","2025-12-16 10:11:58.434566","2025-12-16 13:04:10.855999","2025-12-16 16:17:36.473802","2025-12-17 02:07:56.978358","2025-12-17 11:09:02.207676","2025-12-18 16:36:18.43735","2025-12-18 22:57:20.264686","2025-12-19 07:24:50.960198"} (1 row) QUERY PLAN ----------------------------------------------------------------- Foreign Scan Output: (array_agg("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray("timestamp") FROM agg_test.hits (4 rows) array_agg ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ {"2025-12-05 11:51:04.390884","2025-12-05 12:22:20.135213","2025-12-05 14:31:50.452533","2025-12-05 19:06:00.126014","2025-12-05 19:07:10.399278","2025-12-05 20:07:22.673831","2025-12-06 03:25:34.627161","2025-12-06 05:50:56.818572","2025-12-06 13:02:50.972837","2025-12-07 15:42:06.88149","2025-12-07 17:28:58.124117","2025-12-07 23:20:36.618385","2025-12-08 01:59:58.417052","2025-12-08 03:00:24.806643","2025-12-08 14:42:58.34422","2025-12-08 20:14:32.23635","2025-12-09 00:08:20.392948","2025-12-10 00:39:44.518284","2025-12-10 00:49:32.950914","2025-12-10 04:57:48.584719","2025-12-10 09:29:52.666577","2025-12-10 13:40:28.486178","2025-12-10 16:24:16.877779","2025-12-12 09:52:04.236867","2025-12-12 20:46:06.572602","2025-12-12 23:50:54.686406","2025-12-13 06:58:08.868876","2025-12-13 10:27:26.390655","2025-12-13 14:15:10.219085","2025-12-13 14:54:36.17439","2025-12-13 17:08:04.502729","2025-12-13 18:05:14.46441","2025-12-13 21:09:06.290341","2025-12-14 11:21:28.869821","2025-12-14 17:21:16.478761","2025-12-14 22:32:04.449588","2025-12-15 07:35:16.55788","2025-12-15 16:41:30.608217","2025-12-15 17:07:24.893024","2025-12-15 18:34:26.171566","2025-12-15 21:17:32.577173","2025-12-16 09:13:10.107266","2025-12-16 10:11:58.434566","2025-12-16 13:04:10.855999","2025-12-16 16:17:36.473802","2025-12-17 02:07:56.978358","2025-12-17 11:09:02.207676","2025-12-18 16:36:18.43735","2025-12-18 22:57:20.264686","2025-12-19 07:24:50.960198"} (1 row) QUERY PLAN ------------------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray("timestamp") FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {"2025-12-10 16:24:16.877779","2025-12-12 09:52:04.236867","2025-12-13 10:27:26.390655","2025-12-14 22:32:04.449588","2025-12-15 16:41:30.608217","2025-12-15 17:07:24.893024","2025-12-16 10:11:58.434566","2025-12-16 16:17:36.473802","2025-12-17 02:07:56.978358","2025-12-18 16:36:18.43735"} (1 row) QUERY PLAN ------------------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray("timestamp") FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {"2025-12-10 16:24:16.877779","2025-12-12 09:52:04.236867","2025-12-13 10:27:26.390655","2025-12-14 22:32:04.449588","2025-12-15 16:41:30.608217","2025-12-15 17:07:24.893024","2025-12-16 10:11:58.434566","2025-12-16 16:17:36.473802","2025-12-17 02:07:56.978358","2025-12-18 16:36:18.43735"} (1 row) -- array_agg(Date) QUERY PLAN --------------------------------------------------------------- Foreign Scan Output: (array_agg(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(datestamp) FROM agg_test.hits (4 rows) array_agg ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {2025-12-05,2025-12-05,2025-12-05,2025-12-05,2025-12-05,2025-12-05,2025-12-06,2025-12-06,2025-12-06,2025-12-07,2025-12-07,2025-12-07,2025-12-08,2025-12-08,2025-12-08,2025-12-08,2025-12-09,2025-12-10,2025-12-10,2025-12-10,2025-12-10,2025-12-10,2025-12-10,2025-12-12,2025-12-12,2025-12-12,2025-12-13,2025-12-13,2025-12-13,2025-12-13,2025-12-13,2025-12-13,2025-12-13,2025-12-14,2025-12-14,2025-12-14,2025-12-15,2025-12-15,2025-12-15,2025-12-15,2025-12-15,2025-12-16,2025-12-16,2025-12-16,2025-12-16,2025-12-17,2025-12-17,2025-12-18,2025-12-18,2025-12-19} (1 row) QUERY PLAN --------------------------------------------------------------- Foreign Scan Output: (array_agg(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(datestamp) FROM agg_test.hits (4 rows) array_agg ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {2025-12-05,2025-12-05,2025-12-05,2025-12-05,2025-12-05,2025-12-05,2025-12-06,2025-12-06,2025-12-06,2025-12-07,2025-12-07,2025-12-07,2025-12-08,2025-12-08,2025-12-08,2025-12-08,2025-12-09,2025-12-10,2025-12-10,2025-12-10,2025-12-10,2025-12-10,2025-12-10,2025-12-12,2025-12-12,2025-12-12,2025-12-13,2025-12-13,2025-12-13,2025-12-13,2025-12-13,2025-12-13,2025-12-13,2025-12-14,2025-12-14,2025-12-14,2025-12-15,2025-12-15,2025-12-15,2025-12-15,2025-12-15,2025-12-16,2025-12-16,2025-12-16,2025-12-16,2025-12-17,2025-12-17,2025-12-18,2025-12-18,2025-12-19} (1 row) QUERY PLAN ----------------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(datestamp) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ----------------------------------------------------------------------------------------------------------------- {2025-12-10,2025-12-12,2025-12-13,2025-12-14,2025-12-15,2025-12-15,2025-12-16,2025-12-16,2025-12-17,2025-12-18} (1 row) QUERY PLAN ----------------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(datestamp) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ----------------------------------------------------------------------------------------------------------------- {2025-12-10,2025-12-12,2025-12-13,2025-12-14,2025-12-15,2025-12-15,2025-12-16,2025-12-16,2025-12-17,2025-12-18} (1 row) -- array_agg(String) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (array_agg(path)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(path) FROM agg_test.hits (4 rows) array_agg ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {/users/283434,/users/802683,/search,/users/283434,/users/7392323,/users/7392323,/users/7392323,/widgets/voluptatem,/users,/users,/users/802683,/search,/search,/users/802683,/search,/profile,/widgets/voluptatem,/users/1321945,/users,/widgets/natus,/users/802683,/widgets/voluptatem,/widgets/aperiam,/widgets/totam,/search,/widgets/natus,/search,/widgets/omnis,/users,/users/1739238,/users/283434,/search,/users/1739238,/widgets/omnis,/widgets/omnis,/widgets/natus,/users/283434,/widgets/totam,/widgets/voluptatem,/widgets/aperiam,/widgets,/search,/widgets,/search,/widgets/voluptatem,/widgets/totam,/search,/search,/widgets/omnis,/users/802683} (1 row) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (array_agg(path)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(path) FROM agg_test.hits (4 rows) array_agg -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {'/users/283434','/users/802683','/search','/users/283434','/users/7392323','/users/7392323','/users/7392323','/widgets/voluptatem','/users','/users','/users/802683','/search','/search','/users/802683','/search','/profile','/widgets/voluptatem','/users/1321945','/users','/widgets/natus','/users/802683','/widgets/voluptatem','/widgets/aperiam','/widgets/totam','/search','/widgets/natus','/search','/widgets/omnis','/users','/users/1739238','/users/283434','/search','/users/1739238','/widgets/omnis','/widgets/omnis','/widgets/natus','/users/283434','/widgets/totam','/widgets/voluptatem','/widgets/aperiam','/widgets','/search','/widgets','/search','/widgets/voluptatem','/widgets/totam','/search','/search','/widgets/omnis','/users/802683'} (1 row) QUERY PLAN ------------------------------------------------------------------------------------------ Foreign Scan Output: (array_agg(path)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(path) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg -------------------------------------------------------------------------------------------------------------------------------------------------------- {/widgets/aperiam,/widgets/totam,/widgets/omnis,/widgets/natus,/widgets/totam,/widgets/voluptatem,/widgets,/widgets/voluptatem,/widgets/totam,/search} (1 row) QUERY PLAN ------------------------------------------------------------------------------------------ Foreign Scan Output: (array_agg(path)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(path) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {'/widgets/aperiam','/widgets/totam','/widgets/omnis','/widgets/natus','/widgets/totam','/widgets/voluptatem','/widgets','/widgets/voluptatem','/widgets/totam','/search'} (1 row) -- array_agg(UInt32) QUERY PLAN -------------------------------------------------------------- Foreign Scan Output: (array_agg(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(duration) FROM agg_test.hits (4 rows) array_agg -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {304,541,599,1829,87,243,615,298,1409,83,1332,2011,84,3542,234,48,2498,1784,9,2556,772,253,64,1056,14,148,963,226,2125,3839,4437,2,2,2092,2478,15,1268,66,7672,54,3,81,916,4990,501,31,165,47,148,216} (1 row) QUERY PLAN -------------------------------------------------------------- Foreign Scan Output: (array_agg(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(duration) FROM agg_test.hits (4 rows) array_agg -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {304,541,599,1829,87,243,615,298,1409,83,1332,2011,84,3542,234,48,2498,1784,9,2556,772,253,64,1056,14,148,963,226,2125,3839,4437,2,2,2092,2478,15,1268,66,7672,54,3,81,916,4990,501,31,165,47,148,216} (1 row) QUERY PLAN ---------------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(duration) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ---------------------------------------- {64,1056,226,15,66,7672,916,501,31,47} (1 row) QUERY PLAN ---------------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(duration) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) array_agg ---------------------------------------- {64,1056,226,15,66,7672,916,501,31,47} (1 row) -- array_agg(Decimal) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (array_agg(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(cost) FROM agg_test.hits (4 rows) array_agg ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- {1.29,8.38,4.28,6.51,2.15,3.02,5.94,2.98,5.60,7.01,4.26,7.40,7.55,2.34,7.57,5.66,2.61,3.51,3.52,4.43,5.55,5.24,5.10,1.99,1.81,6.80,3.54,8.14,8.21,4.55,1.33,7.42,2.23,5.24,6.04,8.53,4.43,3.57,2.47,1.20,3.55,8.17,8.24,2.36,4.79,6.75,8.90,7.69,8.09,5.90} (1 row) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (array_agg(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(cost) FROM agg_test.hits (4 rows) array_agg ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ {1.29,8.38,4.28,6.51,2.15,3.02,5.94,2.98,5.6,7.01,4.26,7.4,7.55,2.34,7.57,5.66,2.61,3.51,3.52,4.43,5.55,5.24,5.1,1.99,1.81,6.8,3.54,8.14,8.21,4.55,1.33,7.42,2.23,5.24,6.04,8.53,4.43,3.57,2.47,1.2,3.55,8.17,8.24,2.36,4.79,6.75,8.9,7.69,8.09,5.9} (1 row) QUERY PLAN -------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(cost) FROM agg_test.hits WHERE ((cost < 1000000000)) (4 rows) array_agg ----------------------------------------------------- {5.10,1.99,8.14,8.53,3.57,2.47,8.24,4.79,6.75,7.69} (1 row) QUERY PLAN -------------------------------------------------------------------------------------- Foreign Scan Output: (array_agg(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT groupArray(cost) FROM agg_test.hits WHERE ((cost < 1000000000)) (4 rows) array_agg ---------------------------------------------------- {5.1,1.99,8.14,8.53,3.57,2.47,8.24,4.79,6.75,7.69} (1 row) -- min(UInt64) QUERY PLAN ------------------------------------------------- Foreign Scan Output: (min(id)) Relations: Aggregate on (hits) Remote SQL: SELECT min(id) FROM agg_test.hits (4 rows) min ---------- 41607833 (1 row) QUERY PLAN ------------------------------------------------- Foreign Scan Output: (min(id)) Relations: Aggregate on (hits) Remote SQL: SELECT min(id) FROM agg_test.hits (4 rows) min ---------- 41607833 (1 row) QUERY PLAN --------------------------------------------------------------------------------- Foreign Scan Output: (min(id)) Relations: Aggregate on (hits) Remote SQL: SELECT min(id) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min ---------- 41607833 (1 row) QUERY PLAN --------------------------------------------------------------------------------- Foreign Scan Output: (min(id)) Relations: Aggregate on (hits) Remote SQL: SELECT min(id) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min ---------- 41607833 (1 row) -- min(DateTime64) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (min("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT min("timestamp") FROM agg_test.hits (4 rows) min ---------------------------- 2025-12-05 11:51:04.390884 (1 row) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (min("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT min("timestamp") FROM agg_test.hits (4 rows) min ---------------------------- 2025-12-05 11:51:04.390884 (1 row) QUERY PLAN ------------------------------------------------------------------------------------------ Foreign Scan Output: (min("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT min("timestamp") FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min ---------------------------- 2025-12-10 16:24:16.877779 (1 row) QUERY PLAN ------------------------------------------------------------------------------------------ Foreign Scan Output: (min("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT min("timestamp") FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min ---------------------------- 2025-12-10 16:24:16.877779 (1 row) -- min(Date) QUERY PLAN -------------------------------------------------------- Foreign Scan Output: (min(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT min(datestamp) FROM agg_test.hits (4 rows) min ------------ 2025-12-05 (1 row) QUERY PLAN -------------------------------------------------------- Foreign Scan Output: (min(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT min(datestamp) FROM agg_test.hits (4 rows) min ------------ 2025-12-05 (1 row) QUERY PLAN ---------------------------------------------------------------------------------------- Foreign Scan Output: (min(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT min(datestamp) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min ------------ 2025-12-10 (1 row) QUERY PLAN ---------------------------------------------------------------------------------------- Foreign Scan Output: (min(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT min(datestamp) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min ------------ 2025-12-10 (1 row) -- min(String) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (min(path)) Relations: Aggregate on (hits) Remote SQL: SELECT min(path) FROM agg_test.hits (4 rows) min ---------- /profile (1 row) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (min(path)) Relations: Aggregate on (hits) Remote SQL: SELECT min(path) FROM agg_test.hits (4 rows) min ---------- /profile (1 row) QUERY PLAN ----------------------------------------------------------------------------------- Foreign Scan Output: (min(path)) Relations: Aggregate on (hits) Remote SQL: SELECT min(path) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min --------- /search (1 row) QUERY PLAN ----------------------------------------------------------------------------------- Foreign Scan Output: (min(path)) Relations: Aggregate on (hits) Remote SQL: SELECT min(path) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min --------- /search (1 row) -- min(UInt32) QUERY PLAN ------------------------------------------------------- Foreign Scan Output: (min(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT min(duration) FROM agg_test.hits (4 rows) min ----- 2 (1 row) QUERY PLAN ------------------------------------------------------- Foreign Scan Output: (min(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT min(duration) FROM agg_test.hits (4 rows) min ----- 2 (1 row) QUERY PLAN --------------------------------------------------------------------------------------- Foreign Scan Output: (min(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT min(duration) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min ----- 15 (1 row) QUERY PLAN --------------------------------------------------------------------------------------- Foreign Scan Output: (min(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT min(duration) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) min ----- 15 (1 row) -- min(Decimal) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (min(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT min(cost) FROM agg_test.hits (4 rows) min ------ 1.20 (1 row) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (min(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT min(cost) FROM agg_test.hits (4 rows) min ----- 1.2 (1 row) QUERY PLAN ------------------------------------------------------------------------------- Foreign Scan Output: (min(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT min(cost) FROM agg_test.hits WHERE ((cost < 1000000000)) (4 rows) min ------ 1.99 (1 row) QUERY PLAN ------------------------------------------------------------------------------- Foreign Scan Output: (min(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT min(cost) FROM agg_test.hits WHERE ((cost < 1000000000)) (4 rows) min ------ 1.99 (1 row) -- max(UInt64) QUERY PLAN ------------------------------------------------- Foreign Scan Output: (max(id)) Relations: Aggregate on (hits) Remote SQL: SELECT max(id) FROM agg_test.hits (4 rows) max ------------ 4264738908 (1 row) QUERY PLAN ------------------------------------------------- Foreign Scan Output: (max(id)) Relations: Aggregate on (hits) Remote SQL: SELECT max(id) FROM agg_test.hits (4 rows) max ------------ 4264738908 (1 row) QUERY PLAN --------------------------------------------------------------------------------- Foreign Scan Output: (max(id)) Relations: Aggregate on (hits) Remote SQL: SELECT max(id) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max ----------- 914876110 (1 row) QUERY PLAN --------------------------------------------------------------------------------- Foreign Scan Output: (max(id)) Relations: Aggregate on (hits) Remote SQL: SELECT max(id) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max ----------- 914876110 (1 row) -- max(DateTime64) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (max("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT max("timestamp") FROM agg_test.hits (4 rows) max ---------------------------- 2025-12-19 07:24:50.960198 (1 row) QUERY PLAN ---------------------------------------------------------- Foreign Scan Output: (max("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT max("timestamp") FROM agg_test.hits (4 rows) max ---------------------------- 2025-12-19 07:24:50.960198 (1 row) QUERY PLAN ------------------------------------------------------------------------------------------ Foreign Scan Output: (max("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT max("timestamp") FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max --------------------------- 2025-12-18 16:36:18.43735 (1 row) QUERY PLAN ------------------------------------------------------------------------------------------ Foreign Scan Output: (max("timestamp")) Relations: Aggregate on (hits) Remote SQL: SELECT max("timestamp") FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max --------------------------- 2025-12-18 16:36:18.43735 (1 row) -- max(Date) QUERY PLAN -------------------------------------------------------- Foreign Scan Output: (max(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT max(datestamp) FROM agg_test.hits (4 rows) max ------------ 2025-12-19 (1 row) QUERY PLAN -------------------------------------------------------- Foreign Scan Output: (max(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT max(datestamp) FROM agg_test.hits (4 rows) max ------------ 2025-12-19 (1 row) QUERY PLAN ---------------------------------------------------------------------------------------- Foreign Scan Output: (max(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT max(datestamp) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max ------------ 2025-12-18 (1 row) QUERY PLAN ---------------------------------------------------------------------------------------- Foreign Scan Output: (max(datestamp)) Relations: Aggregate on (hits) Remote SQL: SELECT max(datestamp) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max ------------ 2025-12-18 (1 row) -- max(String) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (max(path)) Relations: Aggregate on (hits) Remote SQL: SELECT max(path) FROM agg_test.hits (4 rows) max --------------------- /widgets/voluptatem (1 row) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (max(path)) Relations: Aggregate on (hits) Remote SQL: SELECT max(path) FROM agg_test.hits (4 rows) max --------------------- /widgets/voluptatem (1 row) QUERY PLAN ----------------------------------------------------------------------------------- Foreign Scan Output: (max(path)) Relations: Aggregate on (hits) Remote SQL: SELECT max(path) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max --------------------- /widgets/voluptatem (1 row) QUERY PLAN ----------------------------------------------------------------------------------- Foreign Scan Output: (max(path)) Relations: Aggregate on (hits) Remote SQL: SELECT max(path) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max --------------------- /widgets/voluptatem (1 row) -- max(UInt32) QUERY PLAN ------------------------------------------------------- Foreign Scan Output: (max(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT max(duration) FROM agg_test.hits (4 rows) max ------ 7672 (1 row) QUERY PLAN ------------------------------------------------------- Foreign Scan Output: (max(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT max(duration) FROM agg_test.hits (4 rows) max ------ 7672 (1 row) QUERY PLAN --------------------------------------------------------------------------------------- Foreign Scan Output: (max(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT max(duration) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max ------ 7672 (1 row) QUERY PLAN --------------------------------------------------------------------------------------- Foreign Scan Output: (max(duration)) Relations: Aggregate on (hits) Remote SQL: SELECT max(duration) FROM agg_test.hits WHERE ((duration < 1000000000)) (4 rows) max ------ 7672 (1 row) -- max(Decimal) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (max(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT max(cost) FROM agg_test.hits (4 rows) max ------ 8.90 (1 row) QUERY PLAN --------------------------------------------------- Foreign Scan Output: (max(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT max(cost) FROM agg_test.hits (4 rows) max ----- 8.9 (1 row) QUERY PLAN ------------------------------------------------------------------------------- Foreign Scan Output: (max(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT max(cost) FROM agg_test.hits WHERE ((cost < 1000000000)) (4 rows) max ------ 8.53 (1 row) QUERY PLAN ------------------------------------------------------------------------------- Foreign Scan Output: (max(cost)) Relations: Aggregate on (hits) Remote SQL: SELECT max(cost) FROM agg_test.hits WHERE ((cost < 1000000000)) (4 rows) max ------ 8.53 (1 row) NOTICE: drop cascades to foreign table agg_bin.hits NOTICE: drop cascades to foreign table agg_http.hits