Skip to content

Feat: Add percentage-based sampling for postgres#2596

Merged
mivds merged 5 commits intomainfrom
DTL-1696/postgres-sampling
Feb 25, 2026
Merged

Feat: Add percentage-based sampling for postgres#2596
mivds merged 5 commits intomainfrom
DTL-1696/postgres-sampling

Conversation

@mivds
Copy link
Contributor

@mivds mivds commented Feb 24, 2026

Description

Adds percentage-based sampling support to postgres.

  • Added SQL generation tests in soda-postgres/tests/unit/test_postgres_dialect.py. No data source required.
  • Added a supports_sampler method in the dialect that we can use to check if sampling is supported, and fall back to less optimized flows if not.

Checklist

  • I added a test to verify the new functionality.
  • I verified this PR does not break soda-extensions.

@mivds mivds self-assigned this Feb 24, 2026
@mivds mivds changed the title Dtl 1696/postgres sampling Feat!: Support percentage-based sampling for postgres Feb 24, 2026
@mivds mivds force-pushed the DTL-1696/postgres-sampling branch from 38c3bde to 0138df0 Compare February 24, 2026 11:59
@mivds mivds requested a review from Niels-b February 24, 2026 12:01
@mivds mivds marked this pull request as ready for review February 24, 2026 12:01
@mivds mivds requested a review from m1n0 February 24, 2026 12:01
@mivds mivds changed the title Feat!: Support percentage-based sampling for postgres Feat!: Add percentage-based sampling for postgres Feb 24, 2026
@mivds mivds changed the base branch from main to DTL-1696/split-dialect-datasource February 25, 2026 11:05
@mivds mivds changed the title Feat!: Add percentage-based sampling for postgres Feat: Add percentage-based sampling for postgres Feb 25, 2026
Copy link
Contributor

@Niels-b Niels-b left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work on the new testing methodology. LGTM!

Base automatically changed from DTL-1696/split-dialect-datasource to main February 25, 2026 12:37
Copy link
Contributor

@m1n0 m1n0 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work on the separation+testing!

@mivds mivds force-pushed the DTL-1696/postgres-sampling branch from c28f4a1 to 83d66e0 Compare February 25, 2026 13:08
@mivds mivds force-pushed the DTL-1696/postgres-sampling branch from 83d66e0 to 2a9da32 Compare February 25, 2026 13:09
@sonarqubecloud
Copy link

@mivds mivds merged commit 17b625e into main Feb 25, 2026
41 checks passed
@mivds mivds deleted the DTL-1696/postgres-sampling branch February 25, 2026 14:09
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.

3 participants