MCPcopy Create free account
hub / github.com/ajitpratap0/GoSQLX / SQL

Method SQL

pkg/sql/ast/sql.go:489–494  ·  view source on GitHub ↗

GROUP BY advanced expressions SQL returns the SQL representation of this ROLLUP expression as "ROLLUP(col1, col2, ...)".

()

Source from the content-addressed store, hash-verified

487// SQL returns the SQL representation of this ROLLUP expression as
488// "ROLLUP(col1, col2, ...)".
489func (r *RollupExpression) SQL() string {
490 if r == nil {
491 return ""
492 }
493 return "ROLLUP(" + exprListSQL(r.Expressions) + ")"
494}
495
496// SQL returns the SQL representation of this CUBE expression as
497// "CUBE(col1, col2, ...)".

Callers 2

TestRollupExpression_SQLFunction · 0.95
TestNilSQLFunction · 0.95

Calls 1

exprListSQLFunction · 0.70

Tested by 2

TestRollupExpression_SQLFunction · 0.76
TestNilSQLFunction · 0.76