Repository navigation
docs: give each in-memory operation its real reason (#402) - #403
Merged
Merged
Conversation
What runs where explained the in-memory operations by what PostgreSQL lacks, and several reasons were wrong. Measured on PostgreSQL 16: - Shift/Expand: a bound at infinity stays there since #224, so "an infinity date absorbs the step" was stale. The empty range, time past midnight and a date past .NET's last one still differ. - Length: upper(r)::int8 - lower(r)::int8 widens fine; a temporal range open to infinity fails in PostgreSQL ("cannot subtract infinite dates"). - Values/Split: ARRAY(SELECT generate_series(...)) is one value. - Bridge conversions: built-in range_agg over one-element ranges, no custom aggregate. - Clamp: LEAST/GREATEST skip NULL; one branch for empty, one step for a discrete upper bound. - Value set Intersect/Except: unnest WITH ORDINALITY keeps the left order, canonical only over canonical rows. Add sorts by collation. - The indexers: subscripting reads stored order; a RangeSet's Count and indexer are a subquery over unnest. An in-memory member runs in the final Select only, and Union composes only under some operators. The decisions don't change. The same reasons are corrected in the READMEs, getting-started, value-sets, ranges, testing, AGENTS.md and the XML docs on Split, Values, Shift and Expand of every range type. Claim E31 follows. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This was referenced Oct 25, 2026
Closed
… yet", linking #191 (#402) Co-Authored-By: Claude Opus 5.5 <[email protected]>
…ct markers (#402) The previous commit merged the base branch with its conflicts left in CHANGELOG.md, three package changelogs and docs/efcore.md. Keeps this branch's rows, the #399 changelog row without its calendar sentence, and the calendar factory row as "not translated yet" linking #191. Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #402
Stacked on PR #400 (#399), which adds rows to the same table; merge that one first.
Problem
docs/efcore.md#what-runs-where, and the pages and XML comments that repeat it, explained each in-memory operation by what PostgreSQL lacks. Several reasons were wrong or stale, and the opening implied that no dedicated operator means no translation, whichGapandGapsalready contradict. Two promises were broader than EF Core: "inside aSelectit is safe" (only the final projection runs on the client) and "use these inWhere,OrderByandSelect" (a value setUnioncomposes only under some operators). #402 has the table of each stated reason against what holds.Change
docs/efcore.md#what-runs-where:Gap/Gapsas composed translations.Unioncomposition rules.Shift/Expandno longer claims aninfinitydifference: since Shift/Expand turn a bound that stands for ±infinity into a finite date #224 both sides keep it.Select.getting-started.md,value-sets.md,ranges.mdandtesting.md;Split,Values,ShiftandExpandof all 13 range types ("an EF Core query doesn't translate it" instead of a wrong cause),SetRangeBridgeandValueSetRangeExtensions.Docs:row under### Fixedin[11.0.0-preview.1]of all five.No translation decision changes.
Tests
upper(r)::int8 - lower(r)::int8gives 4294967295 for[-2147483648,2147483647); without the cast it fails withinteger out of range;infinityfails withcannot subtract infinite dates/timestamps;ARRAY(SELECT generate_series(…))gives{1,2,3};range_aggover singletons gives{[1,4),[7,8)};LEAST(GREATEST(15, NULL), 9)gives10for(,10];unnest … WITH ORDINALITYfiltering gives{a,e};[0]/[3]are NULL;unnestover a multirange counts 2 and picks[5,7);(,);'23:00'::time + 2 hgives01:00;'9999-12-30'::date + 5gives10000-01-04.infinitybehaviour ofShiftisInfinityShiftRoundTripTests.The 10.x half follows as a cherry-pick stacked on PR #401.
🤖 Generated with Claude Code