Skip to content
Snippets Groups Projects
Commit 5771a59a authored by tbrehm's avatar tbrehm
Browse files

Added --force switch to mysql command when the db dump gets imported back inti...

Added --force switch to mysql command when the db dump gets imported back inti the database so that the import continues even if a database table is missing.
parent f13717cc
No related branches found
No related tags found
No related merge requests found
...@@ -99,10 +99,10 @@ function updateDbAndIni() { ...@@ -99,10 +99,10 @@ function updateDbAndIni() {
//** load old data back into database //** load old data back into database
if( !empty($conf["mysql"]["admin_password"]) ) { if( !empty($conf["mysql"]["admin_password"]) ) {
system("mysql --default-character-set=".$conf['mysql']['charset']." -h '".$conf['mysql']['host']."' -u '".$conf['mysql']['admin_user']."' -p'".$conf['mysql']['admin_password']."' ".$conf['mysql']['database']." < existing_db.sql"); system("mysql --default-character-set=".$conf['mysql']['charset']." --force -h '".$conf['mysql']['host']."' -u '".$conf['mysql']['admin_user']."' -p'".$conf['mysql']['admin_password']."' ".$conf['mysql']['database']." < existing_db.sql");
} else { } else {
system("mysql --default-character-set=".$conf['mysql']['charset']." -h '".$conf['mysql']['host']."' -u '".$conf['mysql']['admin_user']."' ".$conf['mysql']['database']." < existing_db.sql"); system("mysql --default-character-set=".$conf['mysql']['charset']." --force -h '".$conf['mysql']['host']."' -u '".$conf['mysql']['admin_user']."' ".$conf['mysql']['database']." < existing_db.sql");
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment