Skip to content
  • Ryuta Kamizono's avatar
    15e3e9cd
    Ensure to calculate column aliases after all table aliases are constructed · 15e3e9cd
    Ryuta Kamizono authored
    Currently, column aliases which is used for eager loading are calculated
    before constructing all table aliases in FROM clause.
    
    `JoinDependency#join_constraints` constructs table aliases for `joins`
    first, and then always re-constructs table aliases for eager loading.
    
    If both `joins` and eager loading are given a same table association,
    the re-construction would cause the discrepancy between column aliases
    and table aliases.
    
    To avoid the discrepancy, the column aliases should be calculated after
    all table aliases are constructed.
    
    Fixes #30603.
    15e3e9cd
    Ensure to calculate column aliases after all table aliases are constructed
    Ryuta Kamizono authored
    Currently, column aliases which is used for eager loading are calculated
    before constructing all table aliases in FROM clause.
    
    `JoinDependency#join_constraints` constructs table aliases for `joins`
    first, and then always re-constructs table aliases for eager loading.
    
    If both `joins` and eager loading are given a same table association,
    the re-construction would cause the discrepancy between column aliases
    and table aliases.
    
    To avoid the discrepancy, the column aliases should be calculated after
    all table aliases are constructed.
    
    Fixes #30603.
Loading