Package com.j_spaces.jdbc.executor
Class JoinedQueryExecutor
java.lang.Object
com.j_spaces.jdbc.executor.AbstractQueryExecutor
com.j_spaces.jdbc.executor.JoinedQueryExecutor
- All Implemented Interfaces:
IQueryExecutor,Externalizable,Serializable
Executes a join query. Create a cartesian product of all the tables , keep only the products that
satisfy the where condition
- Since:
- 7.0
- Author:
- anna
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class com.j_spaces.jdbc.executor.AbstractQueryExecutor
AbstractQueryExecutor.EntriesOrderByComparator -
Field Summary
Fields inherited from class com.j_spaces.jdbc.executor.AbstractQueryExecutor
_logger, query -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionexecute(ISpaceProxy space, Transaction txn, int readModifier, int max) voidexecute(AndNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) Execute And expression - execute both children and union the resultsvoidexecute(ExpNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) voidexecute(InNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) Execute IN expression - can be a list of simple values or an inner select queryvoidexecute(NotInNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) execute NOT IN queryvoidexecute(OrNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) Execute Or expression - execute both children and union the resultsgetGroupByComparator(List<SelectColumn> groupColumns) booleangetResults(ExpNode node) protected booleanmatchesExpressionTree(ExpNode root, ISpaceProxy space, Transaction txn, int readModifier, int max) Traverse the binary expression tree non-recursively using a custom stack The tree has to be traversed in postorder - the parent is traversed after its children.voidvoidsetResults(ExpNode node, boolean result) voidMethods inherited from class com.j_spaces.jdbc.executor.AbstractQueryExecutor
aggregate, avg, clear, convertEntriesToResultArrays, count, execute, executeTemplate, extractResults, filterDistinctEntries, getGroupByComparator, getIntermediateResults, getOrderByComparator, getQuery, groupBy, minMax, orderBy, readAll, setResults, sum, traverseExpressionTree
-
Constructor Details
-
JoinedQueryExecutor
public JoinedQueryExecutor() -
JoinedQueryExecutor
-
-
Method Details
-
execute
public IQueryResultSet<IEntryPacket> execute(ISpaceProxy space, Transaction txn, int readModifier, int max) throws SQLException - Throws:
SQLException
-
execute
public void execute(ExpNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) throws SQLException - Throws:
SQLException
-
getResults
-
setResults
-
execute
public void execute(AndNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) throws SQLException Description copied from interface:IQueryExecutorExecute And expression - execute both children and union the results- Throws:
SQLException
-
execute
public void execute(InNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) throws SQLException Description copied from interface:IQueryExecutorExecute IN expression - can be a list of simple values or an inner select query- Throws:
SQLException
-
execute
public void execute(NotInNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) throws SQLException Description copied from interface:IQueryExecutorexecute NOT IN query- Throws:
SQLException
-
execute
public void execute(OrNode exp, ISpaceProxy space, Transaction txn, int readModifier, int max) throws SQLException Description copied from interface:IQueryExecutorExecute Or expression - execute both children and union the results- Throws:
SQLException
-
getGroupByComparator
-
matchesExpressionTree
protected boolean matchesExpressionTree(ExpNode root, ISpaceProxy space, Transaction txn, int readModifier, int max) throws SQLException Traverse the binary expression tree non-recursively using a custom stack The tree has to be traversed in postorder - the parent is traversed after its children.- Throws:
SQLException
-
writeExternal
- Specified by:
writeExternalin interfaceExternalizable- Overrides:
writeExternalin classAbstractQueryExecutor- Throws:
IOException
-
readExternal
- Specified by:
readExternalin interfaceExternalizable- Overrides:
readExternalin classAbstractQueryExecutor- Throws:
IOExceptionClassNotFoundException
-