ClickHouse / ClickHouse/pg_clickhouse

Add support for optionally fetching actual remote cost estimates

Open
#129 0 comments 0 reactions 0 assignees View on GitHub
planner pushdown
Dominant language
C
Stars
283
Forks
21
Avg merge
2d 6h
Merged PRs (30d)
11

Description

Consider supporting actual remote cost estimation. Borrow from postgres_fdw's `use_remote_estimate` (currently a no-op in pg_clickhouse) to trigger fetching actual estimates. postgres_fdw has logic in its `estimate_path_cost_size()` function to execute an `EXPLAIN` on the remote host; perhaps we can do the same with ClickHouse's [EXPLAIN ESTIMATE](https://clickhouse.com/docs/sql-reference/statements/explain#explain-estimate).

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by reviewing pg_clickhouse's current handling of postgres_fdw's use_remote_estimate, then study postgres_fdw's estimate_path_cost_size() logic. Compare that flow with ClickHouse's EXPLAIN ESTIMATE behavior. Done means an optional setting triggers actual remote cost estimates instead of the current no-op.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, clickhouse, postgresql, sql
Domain
backend, database
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.