public class JdbcImplementor.Result extends Object
| Modifier and Type | Method and Description |
|---|---|
SqlNode |
asFrom()
Returns a node that can be included in the FROM clause or a JOIN.
|
SqlNode |
asQuery()
Converts a non-query node into a SELECT node.
|
JdbcImplementor.Builder |
builder(JdbcRel rel,
org.apache.calcite.adapter.jdbc.JdbcImplementor.Clause... clauses)
Once you have a Result of implementing a child relational expression,
call this method to create a Builder to implement the current relational
expression by adding additional clauses to the SQL query.
|
org.apache.calcite.adapter.jdbc.JdbcImplementor.Clause |
maxClause() |
JdbcImplementor.Context |
qualifiedContext()
Returns a context that always qualifies identifiers.
|
SqlSelect |
subSelect() |
public JdbcImplementor.Builder builder(JdbcRel rel, org.apache.calcite.adapter.jdbc.JdbcImplementor.Clause... clauses)
You need to declare which clauses you intend to add. If the clauses are "later", you can add to the same query. For example, "GROUP BY" comes after "WHERE". But if they are the same or earlier, this method will start a new SELECT that wraps the previous result.
When you have called
JdbcImplementor.Builder.setSelect(org.apache.calcite.sql.SqlNodeList),
JdbcImplementor.Builder.setWhere(org.apache.calcite.sql.SqlNode) etc. call
JdbcImplementor.result(org.apache.calcite.sql.SqlNode, java.util.Collection, org.apache.calcite.rel.RelNode)
to fix the new query.
rel - Relational expression being implementedclauses - Clauses that will be generated to implement current
relational expressionpublic org.apache.calcite.adapter.jdbc.JdbcImplementor.Clause maxClause()
public SqlNode asFrom()
public SqlSelect subSelect()
public SqlNode asQuery()
public JdbcImplementor.Context qualifiedContext()
Copyright © 2012–2015 The Apache Software Foundation. All rights reserved.