mini\Database\VirtualDatabase::applyInWithIndexAwareness()
Method
private
Signature
private function applyInWithIndexAwareness(mini\Table\Contracts\TableInterface $table, string $column, mini\Table\Contracts\SetInterface $set): mini\Table\Contracts\TableInterface
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$table |
mini\Table\Contracts\TableInterface |
required | Documentation missing |
$column |
string |
required | Documentation missing |
$set |
mini\Table\Contracts\SetInterface |
required | Documentation missing |
Returns
Documentation
Apply IN filter with index-aware optimization
If the outer table has an index on the IN column but the set doesn't, we iterate the set values and probe the outer table using eq(). This leverages indexes on the outer table for O(k log n) instead of O(n) where k is set size and n is outer table size.