projects
/
Pman.Core
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
9e6db37
)
UpdateDatabase/MysqlLinks.php
author
edward
<edward@roojs.com>
Thu, 10 Dec 2015 06:37:39 +0000
(14:37 +0800)
committer
edward
<edward@roojs.com>
Thu, 10 Dec 2015 06:37:39 +0000
(14:37 +0800)
UpdateDatabase/MysqlLinks.php
patch
|
blob
|
history
diff --git
a/UpdateDatabase/MysqlLinks.php
b/UpdateDatabase/MysqlLinks.php
index
99ddfeb
..
2988ac8
100644
(file)
--- a/
UpdateDatabase/MysqlLinks.php
+++ b/
UpdateDatabase/MysqlLinks.php
@@
-447,9
+447,23
@@
class Pman_Core_UpdateDatabase_MysqlLinks {
$ce = DB_DataObject::factory('core_enum');
$ce = DB_DataObject::factory('core_enum');
- print_R($ce->database());exit;
+ $ce->query("
+ SELECT
+ CCSA.character_set_name csname,
+ CCSA.collation_name collatename
+ FROM
+ information_schema.`TABLES` T,
+ information_schema.`COLLATION_CHARACTER_SET_APPLICABILITY` CCSA
+ WHERE
+ CCSA.collation_name = T.table_collation
+ AND
+ T.table_schema = mydb COLLATE utf8_unicode_ci
+ AND
+ T.table_name = mytb COLLATE utf8_unicode_ci
+
+ ");
+
- $ce->query("CALL mysql_change_charset('{$tbl}')");
}
}