Package com.mysql.cj.xdevapi
Interface SelectStatement
- All Superinterfaces:
Statement<SelectStatement,RowResult>
- All Known Implementing Classes:
SelectStatementImpl
public interface SelectStatement extends Statement<SelectStatement,RowResult>
A statement representing a SELECT query.
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.mysql.cj.xdevapi.Statement
Statement.LockContention -
Method Summary
Modifier and Type Method Description FilterParamsgetFilterParams()ReturnFilterParamsdefined for this statement.SelectStatementgroupBy(java.lang.String... groupBy)Add/replace the aggregation fields for this query.SelectStatementhaving(java.lang.String having)Add/replace the aggregate criteria for this query.SelectStatementlimit(long numberOfRows)Add/replace the row limit for this query.SelectStatementlockExclusive()Locks matching rows exclusively so no other transactions can read or write to them.SelectStatementlockExclusive(Statement.LockContention lockContention)Locks matching rows exclusively so no other transactions can read or write to them, using the provided lock contention option.SelectStatementlockShared()Locks matching rows against updates.SelectStatementlockShared(Statement.LockContention lockContention)Locks matching rows against updates using the provided lock contention option.SelectStatementoffset(long limitOffset)Add/replace the row offset for this query.SelectStatementorderBy(java.lang.String... sortFields)Add/replace the order specification for this query.SelectStatementwhere(java.lang.String searchCondition)Add/replace the search condition for this query.Methods inherited from interface com.mysql.cj.xdevapi.Statement
bind, bind, bind, bind, clearBindings, execute, executeAsync
-
Method Details
-
where
Add/replace the search condition for this query.- Parameters:
searchCondition- search condition expression- Returns:
SelectStatement
-
groupBy
Add/replace the aggregation fields for this query.- Parameters:
groupBy- groupBy expression- Returns:
SelectStatement
-
having
Add/replace the aggregate criteria for this query.- Parameters:
having- having expression- Returns:
SelectStatement
-
orderBy
Add/replace the order specification for this query.- Parameters:
sortFields- sort expression- Returns:
SelectStatement
-
limit
Add/replace the row limit for this query.- Parameters:
numberOfRows- limit- Returns:
SelectStatement
-
offset
Add/replace the row offset for this query.- Parameters:
limitOffset- limit offset- Returns:
SelectStatement
-
lockShared
SelectStatement lockShared()Locks matching rows against updates.- Returns:
SelectStatement
-
lockShared
Locks matching rows against updates using the provided lock contention option.- Parameters:
lockContention- TheStatement.LockContentionvalue to set.- Returns:
SelectStatement
-
lockExclusive
SelectStatement lockExclusive()Locks matching rows exclusively so no other transactions can read or write to them.- Returns:
SelectStatement
-
lockExclusive
Locks matching rows exclusively so no other transactions can read or write to them, using the provided lock contention option.- Parameters:
lockContention- TheStatement.LockContentionvalue to set.- Returns:
SelectStatement
-
getFilterParams
FilterParams getFilterParams()ReturnFilterParamsdefined for this statement.- Returns:
FilterParams
-