mini\Database\PartialQuery::where() Method

public

Signature

public function where(string $sql, array $params = array (
)): self

Parameters

Name Type Default Description
$sql string required Documentation missing
$params array array ( ) Documentation missing

Returns

self

Documentation

Add a WHERE clause with raw SQL

The SQL expression is parsed into AST and ANDed with existing conditions. Placeholders (?) in the SQL are matched with the params array.

If pagination exists (LIMIT/OFFSET), uses barrier() first to preserve window semantics - filtering applies to the paginated result, not before.

Source

src/Database/PartialQuery.php:569-595