Package com.exasol.adapter.sql
Class SqlGroupBy
- java.lang.Object
-
- com.exasol.adapter.sql.SqlNode
-
- com.exasol.adapter.sql.SqlExpressionList
-
- com.exasol.adapter.sql.SqlGroupBy
-
public class SqlGroupBy extends SqlExpressionList
Represents a GROUP BY statement.
-
-
Constructor Summary
Constructors Constructor Description SqlGroupBy(List<SqlNode> groupByList)
Create a new instance ofSqlGroupBy
.SqlGroupBy(List<SqlNode> groupByList, boolean singleGroupAggregation)
Create a new instance ofSqlGroupBy
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description <R> R
accept(SqlNodeVisitor<R> visitor)
SeeSqlNodeVisitor
SqlNodeType
getType()
Gets type.boolean
isSingleGroupAggregation()
Check if this group by is a single group aggregation.-
Methods inherited from class com.exasol.adapter.sql.SqlExpressionList
getExpressions
-
-
-
-
Constructor Detail
-
SqlGroupBy
public SqlGroupBy(List<SqlNode> groupByList, boolean singleGroupAggregation)
Create a new instance ofSqlGroupBy
.- Parameters:
groupByList
- list of expressionssingleGroupAggregation
- true if the aggregation is a single group
-
SqlGroupBy
public SqlGroupBy(List<SqlNode> groupByList)
Create a new instance ofSqlGroupBy
.- Parameters:
groupByList
- list of expressions
-
-
Method Detail
-
getType
public SqlNodeType getType()
Description copied from class:SqlNode
Gets type.
-
accept
public <R> R accept(SqlNodeVisitor<R> visitor) throws AdapterException
Description copied from class:SqlNode
SeeSqlNodeVisitor
- Specified by:
accept
in classSqlNode
- Type Parameters:
R
- generic SqlNodeVisitor type- Parameters:
visitor
- The visitor object on which the appropriate visit(sqlNode) method is called- Returns:
- visited object
- Throws:
AdapterException
- can be thrown
-
isSingleGroupAggregation
public boolean isSingleGroupAggregation()
Check if this group by is a single group aggregation.- Returns:
- true if this group by is a single group aggregation
-
-