class TableSelect implements Executable (View source)

Class TableSelect

Methods

bind(array $placeholder_values)

Binds a value to a specific placeholder.

execute()

Execute the select statement by chaining it with the execute() method.

groupBy(mixed $sort_expr)

Sets a grouping criteria for the result set.

having(string $sort_expr)

Sets a condition for records to consider in aggregate function operations.

limit(int $rows)

Sets the maximum number of records or documents to return.

lockExclusive(int|null $lock_waiting_option)

Execute a read operation with EXCLUSIVE LOCK. Only one lock can be active at a time.

lockShared(int|null $lock_waiting_option)

Execute a read operation with SHARED LOCK. Only one lock can be active at a time.

offset(int $position)

Skip given number of rows in result.

orderby(string|string[] ...$sort_expr)

Sets the order by criteria.

where(string $where_expr)

Sets the search condition to filter.

Details

TableSelect bind(array $placeholder_values)

Binds a value to a specific placeholder.

Parameters

array $placeholder_values

Return Value

TableSelect

Result execute()

Execute the select statement by chaining it with the execute() method.

Return Value

Result

TableSelect groupBy(mixed $sort_expr)

Sets a grouping criteria for the result set.

Parameters

mixed $sort_expr

Return Value

TableSelect

TableSelect having(string $sort_expr)

Sets a condition for records to consider in aggregate function operations.

Parameters

string $sort_expr

Return Value

TableSelect

TableSelect limit(int $rows)

Sets the maximum number of records or documents to return.

Parameters

int $rows

Return Value

TableSelect

TableSelect lockExclusive(int|null $lock_waiting_option)

Execute a read operation with EXCLUSIVE LOCK. Only one lock can be active at a time.

Parameters

int|null $lock_waiting_option

Return Value

TableSelect

TableSelect lockShared(int|null $lock_waiting_option)

Execute a read operation with SHARED LOCK. Only one lock can be active at a time.

Parameters

int|null $lock_waiting_option

Return Value

TableSelect

TableSelect offset(int $position)

Skip given number of rows in result.

Parameters

int $position

Return Value

TableSelect

TableSelect orderby(string|string[] ...$sort_expr)

Sets the order by criteria.

Parameters

string|string[] ...$sort_expr

Return Value

TableSelect

TableSelect where(string $where_expr)

Sets the search condition to filter.

Parameters

string $where_expr

Return Value

TableSelect