Skip to content

Rule 15: Use Merge Interval for OR expansion detection#349

Merged
erikdarlingdata merged 1 commit into
devfrom
fix/rules-13-14-15
Feb 27, 2026
Merged

Rule 15: Use Merge Interval for OR expansion detection#349
erikdarlingdata merged 1 commit into
devfrom
fix/rules-13-14-15

Conversation

@erikdarlingdata
Copy link
Copy Markdown
Owner

Summary

  • Rule 15 (Join OR Clause): Replace HasJoinAncestor with HasMergeIntervalAncestor — the Merge Interval + TopN Sort pattern is the definitive fingerprint for OR expansion in join predicates, more reliable than checking for a join ancestor

Test plan

  • dotnet build clean (0 errors)
  • plan-b 32/32 tests pass

🤖 Generated with Claude Code

…on detection

Rule 13: Detect GetRangeThroughConvert (CONVERT/CAST on column) in
addition to GetRangeWithMismatchedTypes, with distinct messages.

Rule 14: Warn when cache hits (rewinds) < 5x cache misses (rebinds).
Critical when hits < misses (net negative). Replaces confusing
rebinds*2 >= rewinds condition.

Rule 15: Use Merge Interval ancestor instead of join ancestor to
detect OR expansion. Merge Interval + TopN Sort is the definitive
fingerprint for this pattern.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@erikdarlingdata erikdarlingdata merged commit a9da80b into dev Feb 27, 2026
3 checks passed
@erikdarlingdata erikdarlingdata deleted the fix/rules-13-14-15 branch February 27, 2026 15:36
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