Keep source column references as Arel attributes - #589
Open
nertzy wants to merge 1 commit into
Open
Conversation
Use physical source attributes directly in association projections instead of interpolating qualified names and wrapping rendered SQL. Preserve the separate normalized and foreign derived-alias expressions, as well as the existing String rendering interfaces. Cover model alias collisions and trusted JSON source expressions through public behavior.
nertzy
force-pushed
the
arel/source-columns
branch
from
September 7, 2026 15:05
e7b39c6 to
613b723
Compare
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.
Keep original column references as Arel attributes instead of rendering qualified names and parsing them back into SQL fragments for association projections.
A column's physical source remains distinct from its normalized search expression. Foreign columns likewise distinguish the original association table from the derived search subquery. Existing
full_nameandto_sqlString interfaces remain available.Aggregate inputs still skip NULLs rather than coalescing them early. Public behavior coverage checks physical columns shadowed by model attribute aliases and trusted JSON expressions evaluated before aggregation.
Builds on #588. Quoted-value nodes and expression-boundary cleanup will follow separately.