AddSelectStar returns a Rule that appends a wildcard * column to the SELECT list of a SELECT statement. This is a convenience wrapper around AddColumn with an *ast.Identifier{Name: "*"} argument. Returns ErrUnsupportedStatement for non-SELECT statements.
()
| 107 | // |
| 108 | // Returns ErrUnsupportedStatement for non-SELECT statements. |
| 109 | func AddSelectStar() Rule { |
| 110 | return AddColumn(&ast.Identifier{Name: "*"}) |
| 111 | } |
| 112 | |
| 113 | // columnMatches checks if a column expression matches the given name. |
| 114 | func columnMatches(expr ast.Expression, name string) bool { |