Uses of Class
org.apache.empire.db.DBCommand
Packages that use DBCommand
Package
Description
This package contains implmentations of Empire's data and metadata interfaces for JavaBeans of Data Tranfer Objects (DTO's).
This package contains the core Empire-DB implementation classes.
This package contains SQL-generator classes for column expressions.
This package contains SQL-generator classes for compare expressions used in the where and having clause.
This package contains SQL-generator classes for join expressions used in the from clause.
This package contains SQL-generator classes for set expressions used in the set clause.
This package contains classes necessary to support the H2 database system.
This package contains classes necessary to support the HSQLDB database system.
This package contains classes necessary to support the MySQL database system.
This package contains classes necessary to support the Oracle database system.
This package contains classes necessary to support the PostgreSQL database system.
This package contains classes necessary to support the Microsoft SQL-Server database system.
-
Uses of DBCommand in org.apache.empire.data.bean
Methods in org.apache.empire.data.bean that return DBCommandModifier and TypeMethodDescriptionBeanResult.getCommand()Returns the current command Used to add constraints, order, grouping etc.Constructors in org.apache.empire.data.bean with parameters of type DBCommandModifierConstructorDescriptionBeanResult(Class<T> beanType, DBCommand cmd) Create a bean result from a command object. -
Uses of DBCommand in org.apache.empire.db
Fields in org.apache.empire.db declared as DBCommandMethods in org.apache.empire.db that return DBCommandModifier and TypeMethodDescriptionDBCommand.clone()Creates a clone of this class.DBContext.createCommand()DBDatabase.createCommand()Creates a new Command object for this database Deprecated instead use context.createCommand();protected DBCommandDBRowSet.createRecordCommand(DBContext context) Creates a new command object for record handing May use Prepared statements even if disabled in contextDBCmdParam.getCmd()Returns the command this parameter belongs toprotected DBCommandDBQuery.getCommandFromExpression()returns the command from the underlying command expression or throws an exceptionfinal DBCommandDBCommand.groupAll()Adds all select expressions which are not aggregates to the Group By clausefinal DBCommandDBCommand.groupBy(Collection<? extends DBColumnExpr> columns) Adds a collection of columns to the Group By clause of an sql statement.DBCommand.groupBy(DBColumnExpr columnExpr) Adds a column expression to the Group By clause of an sql statement.final DBCommandDBCommand.groupBy(DBColumnExpr... exprs) Adds a list of columns to the Group By clause of an sql statement.DBCommand.having(DBCompareExpr expr) adds a constraint to the having clause.final DBCommandDBCommand.join(DBColumn[] left, DBColumn[] right, DBJoinType joinType, DBCompareExpr... addlConstraints) Multi-Column version of column based join expressionfinal DBCommandDBCommand.join(DBColumnExpr left, DBColumn right, DBJoinType joinType, DBCompareExpr... addlConstraints) Adds a join based on two columns to the list of join expressions.final DBCommandDBCommand.join(DBColumnExpr left, DBColumn right, DBCompareExpr... addlConstraints) Adds an inner join based on two columns to the list of join expressions.final DBCommandAdds a cross join for two tables or views New in release 3.1: Use left.on(right)) insteadfinal DBCommandDBCommand.join(DBRowSet rowset, DBCompareExpr cmp) Adds an inner join based on a compare expression to the command.final DBCommandDBCommand.join(DBRowSet rowset, DBCompareExpr cmp, DBJoinType joinType) Adds a join based on a compare expression to the command.DBCommand.join(DBJoinExpr join) Adds a join to the list of join expressions.final DBCommandDBCommand.join(DBJoinExpr join, DBJoinType joinType) Adds a join to the list of join expressions.final DBCommandDBCommand.joinLeft(DBColumnExpr left, DBColumn right, DBCompareExpr... addlConstraints) Adds a left join based on two columns to the list of join expressions.final DBCommandDBCommand.joinLeft(DBJoinExpr join) Adds a left join to the list of join expressions.final DBCommandDBCommand.joinRight(DBColumnExpr left, DBColumn right, DBCompareExpr... addlConstraints) Adds a right join based on two columns to the list of join expressions.final DBCommandDBCommand.joinRight(DBJoinExpr join) Adds a left join to the list of join expressions.DBCommand.limitRows(int limitRows) Overridden to change return type from DBCommandExpr to DBCommandprotected DBCommandDBView.newCommand()Use this to create a new View command inside the createCommand() method!DBCommand.orderBy(DBColumnExpr... exprs) Overridden to change return type from DBCommandExpr to DBCommandDBCommand.orderBy(DBColumnExpr expr, boolean desc) Overridden to change return type from DBCommandExpr to DBCommandDBCommand.orderBy(DBOrderByExpr... exprs) Overridden to change return type from DBCommandExpr to DBCommandDBCommand.orderByUpper(DBColumnExpr... expr) Overridden to change return type from DBCommandExpr to DBCommandDBCommand.orderByUpper(DBColumnExpr expr, boolean desc) Overridden to change return type from DBCommandExpr to DBCommandDBCommand.qualifyAll()Makes sure all selected columns are identified by their proper names (qualified)final DBCommandDBCommand.select(Collection<? extends DBColumnExpr> columns) Adds a collection of columns to the select phrase of an sql statement.DBCommand.select(DBColumnExpr expr) Adds a DBColumnExpr object to the Select collectionfinal DBCommandDBCommand.select(DBColumnExpr... exprs) Adds a list of columns to the select phrase of an sql statement.DBCommand.selectDistinct()Sets whether or not the select statement should contain the distinct directive .final DBCommandDBCommand.selectQualified(Collection<? extends DBColumnExpr> columns) Adds a collection of columns to the select phrase of an sql statement.DBCommand.selectQualified(DBColumnExpr... columns) Adds a list of columns with their qualified name to the select phrase of an sql statement.final DBCommandDBCommand.selectSetExpressions()Selects all set expressions that have been set for this commandfinal DBCommandDBCommand.selectSetExpressions(List<DBSetExpr> setExprList) Selects all set expressions i.e. converts all calls like cmd.set(COL.to(VALUE)) into a select of the form cmd.select(VALUE.as(COL))Adds a single set expressions to this command Use column.to(...) to create a set expressionfinal DBCommandAdds a list of set expressions to this command Use column.to(...) to create a set expressionDBCommand.skipRows(int skipRows) Overridden to change return type from DBCommandExpr to DBCommandDBCommand.where(DBCompareExpr expr) Adds a constraint to the where phrase of the sql statement If another restriction already exists for the same column it will be replaced.final DBCommandDBCommand.where(DBCompareExpr... exprs) Adds a list of constraints to the where phrase of the sql statement If another restriction already exists for the same column it will be replaced.Methods in org.apache.empire.db with parameters of type DBCommandModifier and TypeMethodDescriptionvoidvoidAdds an delete statementvoidAdds an insert statementprotected booleanDBQuery.addJoinRestriction(DBCommand cmd, DBColumn updCol, DBColumn joinCol, Object[] key, DBRecordBase record) Adds join restrictions to the supplied command object.voidAdds an update statementvoidDBCmdParamList.completeParamUsage(DBCommand cmd) internally used to remove unused Command Params from list Note: Only one thread my generate an SQL statementintDBContext.executeDelete(DBTable from, DBCommand cmd) intDBContext.executeInsert(DBCommand cmd) intDBContext.executeInsertInto(DBTable table, DBCommand cmd) intDBContext.executeUpdate(DBCommand cmd) DBUtils.queryRecordList(DBCommand cmd, DBRowSet rowset) Executes a query and returns a list of DBRecord itemsfinal <R extends DBRecordBase>
List<R>DBUtils.queryRecordList(DBCommand cmd, DBRowSet rowset, Class<R> recordType) Executes a query and returns a list of DBRecord items<R extends DBRecordBase>
List<R>DBUtils.queryRecordList(DBCommand cmd, DBRecordListFactory<R> factory, int first, int pageSize) Executes a query and returns a list of DBRecord itemsintDBUtils.queryRowCount(DBCommand cmd) Returns the number of rows returned by executing the select statementprotected voidDBRowSet.readRecord(DBRecordBase record, DBCommand cmd) Reads a single record from the database using the given command object.
If a record is found the DBRecord object will hold all record data.voidDBCmdParamList.resetParamUsage(DBCommand cmd) internally used to reset the command param usage count.Constructors in org.apache.empire.db with parameters of type DBCommandModifierConstructorDescriptionprotectedDBCmdParam(DBCommand cmd, DataType type, Object value) Protected constructor used e.g. by DBCommand.addParam(...) -
Uses of DBCommand in org.apache.empire.db.context
Methods in org.apache.empire.db.context that return DBCommandModifier and TypeMethodDescriptionfinal DBCommandDBContextBase.createCommand()Creates a new Command object for the given databaseMethods in org.apache.empire.db.context with parameters of type DBCommandModifier and TypeMethodDescriptionfinal intDBContextBase.executeDelete(DBTable from, DBCommand cmd) Executes a Delete statement from a command objectfinal intDBContextBase.executeInsert(DBCommand cmd) Executes an Insert statement from a command objectfinal intDBContextBase.executeInsertInto(DBTable table, DBCommand cmd) Executes an InsertInfo statement from a command objectfinal intDBContextBase.executeUpdate(DBCommand cmd) Executes an Update statement from a command object -
Uses of DBCommand in org.apache.empire.db.expr.column
Methods in org.apache.empire.db.expr.column with parameters of type DBCommandModifier and TypeMethodDescriptionvoidDBAbstractFuncExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBAliasExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBCoalesceExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBDecodeExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBParenthesisExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBPreparable.prepareParams(DBCommand cmd, DBExpr parent) Prepares an expression for a query This function is called by DBCommand in order to add values as query parameters instead of being literally included in the sql statement Please Note: This function is internally called.voidDBScalarExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBValueExpr.prepareParams(DBCommand cmd, DBExpr parent) -
Uses of DBCommand in org.apache.empire.db.expr.compare
Methods in org.apache.empire.db.expr.compare with parameters of type DBCommandModifier and TypeMethodDescriptionCopy CommandCopy Commandabstract DBCompareExprinternally used for command cloningCopy CommandCopy CommandvoidDBCompareAndOrExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBCompareColExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBCompareNotExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBCompareParenthesisExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBExistsExpr.prepareParams(DBCommand cmd, DBExpr parent) -
Uses of DBCommand in org.apache.empire.db.expr.join
Methods in org.apache.empire.db.expr.join with parameters of type DBCommandModifier and TypeMethodDescriptionCopy CommandCopy CommandCopy Commandabstract DBJoinExprCopy CommandvoidDBColumnJoinExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBCompareJoinExpr.prepareParams(DBCommand cmd, DBExpr parent) voidDBCrossJoinExpr.prepareParams(DBCommand cmd, DBExpr parent) -
Uses of DBCommand in org.apache.empire.db.expr.set
Methods in org.apache.empire.db.expr.set with parameters of type DBCommand -
Uses of DBCommand in org.apache.empire.db.list
Methods in org.apache.empire.db.list with parameters of type DBCommandModifier and TypeMethodDescriptionvoidDBRecordListFactory.prepareQuery(DBCommand cmd, DBContext context) voidDBRecordListFactoryImpl.prepareQuery(DBCommand cmd, DBContext context) -
Uses of DBCommand in org.apache.empire.dbms
Subclasses of DBCommand in org.apache.empire.dbmsModifier and TypeClassDescriptionstatic final classDBMSCommand A Default DBCommand implementation with no additional featuresMethods in org.apache.empire.dbms that return DBCommandModifier and TypeMethodDescriptionDBMSHandler.createCommand(boolean autoPrepareStmt) This function creates a DBCommand for this DBMSDBMSHandlerBase.createCommand(boolean autoPrepareStmt) This function creates a DBCommand derived object this database -
Uses of DBCommand in org.apache.empire.dbms.h2
Subclasses of DBCommand in org.apache.empire.dbms.h2Modifier and TypeClassDescriptionstatic classDefines the H2 command type.Methods in org.apache.empire.dbms.h2 that return DBCommand -
Uses of DBCommand in org.apache.empire.dbms.hsql
Subclasses of DBCommand in org.apache.empire.dbms.hsqlModifier and TypeClassDescriptionclassThis class handles the special features of an HSqlDB database.Methods in org.apache.empire.dbms.hsql that return DBCommandModifier and TypeMethodDescriptionDBMSHandlerHSql.createCommand(boolean autoPrepareStmt) Override standard command -
Uses of DBCommand in org.apache.empire.dbms.mysql
Subclasses of DBCommand in org.apache.empire.dbms.mysqlModifier and TypeClassDescriptionstatic classDefines the MySQL command type.Methods in org.apache.empire.dbms.mysql that return DBCommand -
Uses of DBCommand in org.apache.empire.dbms.oracle
Subclasses of DBCommand in org.apache.empire.dbms.oracleModifier and TypeClassDescriptionclassThis class handles the special features of an oracle database.Methods in org.apache.empire.dbms.oracle that return DBCommandModifier and TypeMethodDescriptionDBMSHandlerOracle.createCommand(boolean autoPrepareStmt) Creates a new Oracle command object. -
Uses of DBCommand in org.apache.empire.dbms.postgresql
Subclasses of DBCommand in org.apache.empire.dbms.postgresqlMethods in org.apache.empire.dbms.postgresql that return DBCommandModifier and TypeMethodDescriptionDBCommandPostgres.limitRows(int numRows) DBCommandPostgres.skipRows(int numRows) Methods in org.apache.empire.dbms.postgresql with parameters of type DBCommand -
Uses of DBCommand in org.apache.empire.dbms.sqlite
Subclasses of DBCommand in org.apache.empire.dbms.sqliteModifier and TypeClassDescriptionstatic classDefines the SQLite command type.Methods in org.apache.empire.dbms.sqlite that return DBCommandModifier and TypeMethodDescriptionDBMSHandlerSQLite.createCommand(boolean autoPrepareStmt) Creates a new SQLite command object. -
Uses of DBCommand in org.apache.empire.dbms.sqlserver
Subclasses of DBCommand in org.apache.empire.dbms.sqlserverModifier and TypeClassDescriptionstatic classProvides a DBCommand implementation for Microsoft SQL-ServerMethods in org.apache.empire.dbms.sqlserver that return DBCommand