Package com.arcadedb.query.sql.parser
Class SelectStatement
- java.lang.Object
-
- com.arcadedb.query.sql.parser.SimpleNode
-
- com.arcadedb.query.sql.parser.Statement
-
- com.arcadedb.query.sql.parser.SelectStatement
-
- All Implemented Interfaces:
Node
- Direct Known Subclasses:
SelectWithoutTargetStatement
public class SelectStatement extends Statement
-
-
Field Summary
Fields Modifier and Type Field Description protected GroupBy
groupBy
protected LetClause
letClause
protected OrderBy
orderBy
protected Projection
projection
protected Skip
skip
protected FromClause
target
protected Unwind
unwind
protected WhereClause
whereClause
-
Fields inherited from class com.arcadedb.query.sql.parser.Statement
CUSTOM_STRICT_SQL, limit, originalStatement, timeout
-
Fields inherited from class com.arcadedb.query.sql.parser.SimpleNode
children, firstToken, id, lastToken, parent, parser, value
-
-
Constructor Summary
Constructors Constructor Description SelectStatement(int id)
SelectStatement(SqlParser p, int id)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SelectStatement
copy()
InternalExecutionPlan
createExecutionPlan(CommandContext ctx, boolean enableProfiling)
creates an execution plan for current statementvoid
deserialize(Result fromResult)
boolean
equals(Object o)
ResultSet
execute(Database db, Object[] args, CommandContext parentCtx, boolean usePlanCache)
ResultSet
execute(Database db, Map<String,Object> params, CommandContext parentCtx, boolean usePlanCache)
boolean
executionPlanCanBeCached()
GroupBy
getGroupBy()
LetClause
getLetClause()
OrderBy
getOrderBy()
Projection
getProjection()
Skip
getSkip()
FromClause
getTarget()
Unwind
getUnwind()
WhereClause
getWhereClause()
int
hashCode()
boolean
isIdempotent()
boolean
refersToParent()
Result
serialize()
void
setTarget(FromClause target)
void
setUnwind(Unwind unwind)
void
setWhereClause(WhereClause whereClause)
void
toString(Map<String,Object> params, StringBuilder builder)
void
validate()
-
Methods inherited from class com.arcadedb.query.sql.parser.Statement
createExecutionPlan, createExecutionPlanNoCache, deserializeFromOResult, execute, execute, execute, execute, execute, execute, getLimit, getOriginalStatement, getTimeout, isDDL, setLimit, setOriginalStatement, setTimeout, toString
-
Methods inherited from class com.arcadedb.query.sql.parser.SimpleNode
childrenAccept, dump, getValue, jjtAccept, jjtAddChild, jjtClose, jjtGetChild, jjtGetFirstToken, jjtGetLastToken, jjtGetNumChildren, jjtGetParent, jjtGetValue, jjtOpen, jjtSetFirstToken, jjtSetLastToken, jjtSetParent, jjtSetValue, toString
-
-
-
-
Field Detail
-
target
protected FromClause target
-
projection
protected Projection projection
-
whereClause
protected WhereClause whereClause
-
groupBy
protected GroupBy groupBy
-
orderBy
protected OrderBy orderBy
-
unwind
protected Unwind unwind
-
skip
protected Skip skip
-
letClause
protected LetClause letClause
-
-
Constructor Detail
-
SelectStatement
public SelectStatement(int id)
-
SelectStatement
public SelectStatement(SqlParser p, int id)
-
-
Method Detail
-
getProjection
public Projection getProjection()
-
getTarget
public FromClause getTarget()
-
setTarget
public void setTarget(FromClause target)
-
getWhereClause
public WhereClause getWhereClause()
-
setWhereClause
public void setWhereClause(WhereClause whereClause)
-
getGroupBy
public GroupBy getGroupBy()
-
getOrderBy
public OrderBy getOrderBy()
-
getSkip
public Skip getSkip()
-
getLetClause
public LetClause getLetClause()
-
toString
public void toString(Map<String,Object> params, StringBuilder builder)
-
validate
public void validate() throws CommandSQLParsingException
- Overrides:
validate
in classStatement
- Throws:
CommandSQLParsingException
-
executionPlanCanBeCached
public boolean executionPlanCanBeCached()
- Overrides:
executionPlanCanBeCached
in classStatement
-
execute
public ResultSet execute(Database db, Object[] args, CommandContext parentCtx, boolean usePlanCache)
-
execute
public ResultSet execute(Database db, Map<String,Object> params, CommandContext parentCtx, boolean usePlanCache)
-
createExecutionPlan
public InternalExecutionPlan createExecutionPlan(CommandContext ctx, boolean enableProfiling)
Description copied from class:Statement
creates an execution plan for current statement- Overrides:
createExecutionPlan
in classStatement
- Parameters:
ctx
- the context that will be used to execute the statementenableProfiling
- true to enable profiling, false to disable it- Returns:
- an execution plan
-
copy
public SelectStatement copy()
-
refersToParent
public boolean refersToParent()
- Overrides:
refersToParent
in classStatement
-
getUnwind
public Unwind getUnwind()
-
isIdempotent
public boolean isIdempotent()
- Overrides:
isIdempotent
in classStatement
-
setUnwind
public void setUnwind(Unwind unwind)
-
deserialize
public void deserialize(Result fromResult)
- Overrides:
deserialize
in classStatement
-
-