ci-ouu 发表于 2011-7-7 17:39:46

的确Good

binbin 发表于 2011-7-7 21:52:42

学习。。。

songjian 发表于 2011-7-13 13:20:20

通过php备份还原大数据库是很麻烦的。

as3291363 发表于 2012-2-16 14:44:27

很有用...谢谢分享....!!!!

as3291363 发表于 2012-2-17 11:31:58

不會還原 好像有問題 有bug...執行不成功...兩種方式我都試過了.

大道达人 发表于 2012-3-23 00:27:01

source时候有bug,source是命令行

大道达人 发表于 2012-3-23 00:52:56

命令行连接               
include APPPATH.'config/database.php';
                $file = BASEPATH.'../application/sql/cier.sql';
               
                $host = $db[$active_group]['hostname'];
                $user = $db[$active_group]['username'];
                $pwd= $db[$active_group]['password'];
                $db   = $db[$active_group]['database'];
                /*命令行导入*/
          exec("mysql -h{$host} -u{$user} -p{$pwd} $db < {$file} 2>&1", $output, $ret);
      if ($ret != 0)
      {
            die(implode('<br/>', $output));
      }

gxcnvip 发表于 2012-4-15 23:43:59

导入不成功,什么提示都没有,啥问题?

指尖的殤魂 发表于 2012-4-16 15:40:13

标记个

xuqin 发表于 2012-5-24 11:23:39

支持:victory::victory::victory::victory:
页: 1 [2] 3
查看完整版本: CI数据库备份与还原入门小例子