3 # small script to convert mysql tables to utf-8
8 my $dbh=C4::Context->dbh();
10 my $database=C4::Context->config("database");
11 my $query="Show tables";
12 my $sth=$dbh->prepare($query);
14 while (my @table=$sth->fetchrow_array()){
15 print "Altering table $table[0]\n";
16 my $alter_query="ALTER TABLE $table[0] convert to CHARACTER SET UTF8 collate utf8_general_ci";
17 my $sth2=$dbh->prepare($alter_query);