Skip to content

Commit

Permalink
Fix for lowercase created where clause and for selecting the incorrec…
Browse files Browse the repository at this point in the history
…t where
  • Loading branch information
Vincentv92 committed Jan 8, 2025
1 parent 116ded6 commit 8b2e5a5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Schema/SQLiteSchemaManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ static function (array $a, array $b): int {
if ($tableIndex['partial'] === 1) {
$idx['where'] = $this->connection->fetchOne(
<<<'SQL'
SELECT SUBSTR(sql, INSTR(sql, 'WHERE') + 6)
SELECT SUBSTR(sql, INSTR(lower(sql), 'where ') + LENGTH('where '))
FROM sqlite_master WHERE type = 'index' AND name = (?)
SQL,
[$keyName],
Expand Down

0 comments on commit 8b2e5a5

Please sign in to comment.