Skip to content

dynamic_filters of SegmentedTopKExec->HashJoinExec plans includes orphaned dummy filter #5635

Closed

Description

@barbarj

What happens?

#5553 updated how dynamic filters were handled on additional filter pushdown passes. As a result, plans that have a SegmentedTopKExec inserted between a SortExec and a HashJoinExec end up with an orphaned dummy filter.

The SegmentedTopKExec is inserted after the first pushdown run. At that point, the SortExec has pushed down a filter. After insertion, SegmentedTopKExec removes the need for that filter, but does not remove the filter. This inflates the reported count of dynamic filters used in PgSearchScan.

To Reproduce

See the regression test outputs for any join query involving SegmentedTopKExec

OS:

macOs

ParadeDB Version (e.g. output of SELECT * FROM paradedb.version_info();):

v0.24.3

Are you using ParadeDB Docker, Helm, or the extension(s) standalone?

ParadeDB pg_search Extension

Full Name:

RJ Barman

Affiliation:

ParadeDB

Did you include all relevant data sets for reproducing the issue?

Yes

Did you include the code required to reproduce the issue?

  • Yes, I have

Did you include all relevant configurations (e.g., CPU architecture, PostgreSQL version, Linux distribution) to reproduce the issue?

  • Yes, I have

Activity

  1. self-assigned this
    on Jul 20, 2026
  2. added a commit that references this issue on Jul 28, 2026
  3. barbarj commented on Jul 30, 2026

    @barbarj
    ContributorAuthor

    Once #5766 is merged, fixing this should also remove the need do a second pushdown pass in serialize_physical_plan.rs, as SegmentedTopKExec should be taking ownership of the SortExecs existing filter, removing the need to push down a new one.

  4. removed their assignment
    on Jul 30, 2026
  5. barbarj commented on Jul 30, 2026

    @barbarj
    ContributorAuthor

    @devdattatalele Feel free to /take this since you've been working on the PR for it.

  6. removed their assignment
    on Jul 30, 2026
  7. devdattatalele commented on Jul 30, 2026

    @devdattatalele
    Contributor

    /take

    Will rework #5721 into the ownership-transfer shape once #5766 lands.

  8. added 6 commits that reference this issue on Jul 31, 2026
    6a9fc31
    6b3203a
    41689c4
    73704e6
    a55804a
    9c0d84d
  9. added a commit that references this issue on Aug 7, 2026
    7065032
  10. added a commit that references this issue on Aug 7, 2026
    b0705ea
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

bugSomething isn't workingjoinsPR or issue related to JOINspriority-mediumMedium priority issue

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions