Skip to content

Adding Hooks for OprExpr and NullTest selectivity#770

Open
RuchaSK1 wants to merge 1 commit into
babelfish-for-postgresql:BABEL_6_X_DEV__PG_18_Xfrom
amazon-aurora:jira-babel-6458-part3
Open

Adding Hooks for OprExpr and NullTest selectivity#770
RuchaSK1 wants to merge 1 commit into
babelfish-for-postgresql:BABEL_6_X_DEV__PG_18_Xfrom
amazon-aurora:jira-babel-6458-part3

Conversation

@RuchaSK1

@RuchaSK1 RuchaSK1 commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Description

Adding planner hooks for OpExpr and NullTest selectivity estimation.

These hooks allow Babelfish to override selectivity for:

  • OpExpr: CASE expressions compared to constants
  • NullTest: IS NULL/IS NOT NULL on SubPlan results

Both hooks are guarded by sql_dialect == SQL_DIALECT_TSQL and have no effect on vanilla PostgreSQL behavior.

Issues Resolved

Check List

  • Commits are signed per the DCO using --signoff

By submitting this pull request, I confirm that my contribution is under the terms of the PostgreSQL license, and grant any person obtaining a copy of the contribution permission to relicense all or a portion of my contribution to the PostgreSQL License solely to contribute all or a portion of my contribution to the PostgreSQL open source project.

For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: Rucha Kulkarni <ruchask@amazon.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant