I recently ended up with a database in which all tables where lowercase.
I used the following rather dirty hack to fix this:
put the following code in line ~ 189 of sapphire/core/model/DatabaseAdmin.php
$t = $dataClass;
if(DB::query('SELECT * FROM information_schema.tables WHERE table_schema like binary "'.strtolower($t).'" or Table_Name like binary "'.strtolower($t).'";')->value()) {
DB::query('RENAME TABLE `'.strtolower($t).'` TO `'.($t).'` ;');
}
put the following code in around line 275 of sapphire/core/model/MySQLDatabase.php...
public function fieldList($table) {
$t = $table;
if(DB::query('SELECT * FROM information_schema.tables WHERE table_schema like binary "'.strtolower($t).'" or Table_Name like binary "'.strtolower($t).'";')->value()) {
DB::query('RENAME TABLE `'.strtolower($t).'` TO `'.($t).'` ;');
}