新的邏輯引入了新的bug,會導致在跨多庫連接時,產生表名前綴映射混亂,需要再做邏輯上的修復。
function table_name($tablename) { if(!empty($this->map) && !empty($this->map[$tablename])) { $id = $this->map[$tablename]; if(!empty($this->config[$id]['table附db Map 寫法:
$_config['db']['1']['dbhost'] = 'localhost'; // 服務器地址$_config['db']['1']['dbuser'] = 'root'; // 用戶$_config['db']['1']['dbpw'] = 'root';// 密碼$_config['db']['1']['dbcharset'] = 'gbk';// 字符集$_config['db']['1']['pconnect'] = '0';// 是否持續連接$_config['db']['1']['dbname'] = 'x1';// 數據庫$_config['db']['1']['tablepre'] = 'pre_';// 表名前綴$_config['db']['2']['dbhost'] = 'localhost';.....//再配置一些數據源$_config['db']['xxx_sys']['dbhost'] = 'localhost';//映射$_config['db']['map']['yyy_table'] = 'xxx_sys';上一篇文章:http://www.49028c.com/x3d/p/3913690.html
新聞熱點
疑難解答