Package com.exasol.adapter.sql
Class SqlStatementSelect
- java.lang.Object
-
- com.exasol.adapter.sql.SqlNode
-
- com.exasol.adapter.sql.SqlStatement
-
- com.exasol.adapter.sql.SqlStatementSelect
-
public class SqlStatementSelect extends SqlStatement
We could consider to apply builder pattern here (if time)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
SqlStatementSelect.Builder
Builder forSqlStatementSelect
.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description <R> R
accept(SqlNodeVisitor<R> visitor)
SeeSqlNodeVisitor
static SqlStatementSelect.Builder
builder()
Create a new builder forSqlStatementSelect
.SqlNode
getFromClause()
Gets from clause.SqlExpressionList
getGroupBy()
Gets group by.SqlNode
getHaving()
Gets having.SqlLimit
getLimit()
Gets limit.SqlOrderBy
getOrderBy()
Gets order by.SqlSelectList
getSelectList()
Gets select list.SqlNodeType
getType()
Gets type.SqlNode
getWhereClause()
Gets where clause.boolean
hasFilter()
Has filter boolean.boolean
hasGroupBy()
Has group by boolean.boolean
hasHaving()
Has having boolean.boolean
hasLimit()
Has limit boolean.boolean
hasOrderBy()
Has order by boolean.boolean
hasProjection()
Has projection boolean.
-
-
-
Method Detail
-
hasProjection
public boolean hasProjection()
Has projection boolean.- Returns:
- the boolean
-
hasGroupBy
public boolean hasGroupBy()
Has group by boolean.- Returns:
- the boolean
-
hasHaving
public boolean hasHaving()
Has having boolean.- Returns:
- the boolean
-
hasFilter
public boolean hasFilter()
Has filter boolean.- Returns:
- the boolean
-
hasOrderBy
public boolean hasOrderBy()
Has order by boolean.- Returns:
- the boolean
-
hasLimit
public boolean hasLimit()
Has limit boolean.- Returns:
- the boolean
-
getFromClause
public SqlNode getFromClause()
Gets from clause.- Returns:
- the from clause
-
getSelectList
public SqlSelectList getSelectList()
Gets select list.- Returns:
- the select list
-
getWhereClause
public SqlNode getWhereClause()
Gets where clause.- Returns:
- the where clause
-
getGroupBy
public SqlExpressionList getGroupBy()
Gets group by.- Returns:
- the group by
-
getHaving
public SqlNode getHaving()
Gets having.- Returns:
- the having
-
getOrderBy
public SqlOrderBy getOrderBy()
Gets order by.- Returns:
- the order by
-
getLimit
public SqlLimit getLimit()
Gets limit.- Returns:
- the limit
-
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
-
builder
public static SqlStatementSelect.Builder builder()
Create a new builder forSqlStatementSelect
.- Returns:
- builder instance
-
-