diff --git a/lib/Cake/Model/Datasource/Database/Sqlite.php b/lib/Cake/Model/Datasource/Database/Sqlite.php index 955f51f42..37c3787a8 100644 --- a/lib/Cake/Model/Datasource/Database/Sqlite.php +++ b/lib/Cake/Model/Datasource/Database/Sqlite.php @@ -306,7 +306,7 @@ class Sqlite extends DboSource { foreach (String::tokenize($selectpart, ',', '(', ')') as $part) { $fromPos = stripos($part, ' FROM '); if ($fromPos !== false) { - $selects[] = trim(substr($part, 0, $fromPos)); + $selects[] = trim(substr($part, 0, $fromPos)); break; } $selects[] = $part;