Change Database Collation

From AWBS Wiki
Revision as of 22:53, February 9, 2009 by Awbsrob (Talk | contribs)

Jump to: navigation, search

Some languages require the Database collation to be changed in order to display characters correctly. You will find instructions here on how to change your database collation and configure AWBS to work correctly with this change.

Converting the Database

Copy and paste the example below into a new text file. Give this file a name of convertdb.php (or anything that you will remember, but with the .php extension)

Example:
<?php
$DIR=(dirname(__FILE__));
require($DIR."/../includes/dbconfig.php");
include($workdir."/includes/sessions.php");
include_once($workdir."/config.php");
$tables = mysql_list_tables($dbdatabase);
while (list($table) = mysql_fetch_row($tables)) {
sqlwritesingle("ALTER TABLE $table CONVERT TO CHARACTER SET latin5 COLLATE latin5_turkish_ci;");
echo "$table - DONE
";flush();ob_flush();
}
?>

Extended System Configuration

DBCONFIG.PHP Modification