Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
fix: range subselect alias pointer dereference
  • Loading branch information
ahme-dev authored and andrewmbenton committed Aug 5, 2025
commit 3219da3f9ed365501306ce46ab3c6e8a7a683dc4
8 changes: 7 additions & 1 deletion internal/compiler/output_columns.go
Original file line number Diff line number Diff line change
Expand Up @@ -596,9 +596,15 @@ func (c *Compiler) sourceTables(qc *QueryCatalog, node ast.Node) ([]*Table, erro
if err != nil {
return nil, err
}

var tableName string
if n.Alias != nil {
tableName = *n.Alias.Aliasname
}

tables = append(tables, &Table{
Rel: &ast.TableName{
Name: *n.Alias.Aliasname,
Name: tableName,
},
Columns: cols,
})
Expand Down