sql_orders.php 1.23 KB
<?php
require_once("../../include/config.php");

$var_bash_MainDB = 'cd ../include/System/sql/ && ls &&  mysql -u '.$_LOSP_STORABLE_DATA["config_user"].' --password='.$_LOSP_STORABLE_DATA["config_passwd"].' -D '.$_LOSP_STORABLE_DATA["config_db"];

$var_bash_SrequestDB = 'cd ../include/System/sql/ && ls &&  mysql -u '.$_LOSP_STORABLE_DATA['SREQUEST']["config_user"].' --password='.$_LOSP_STORABLE_DATA['SREQUEST']["config_passwd"].' -D '.$_LOSP_STORABLE_DATA['SREQUEST']["config_db"].'';

$var_bash_export_MainDB_file = $_LOSP_STORABLE_DATA["config_db"].'.'.date('Ymd_Hi').'.sql';
$var_bash_export_MainDB='mysqldump --no-defaults --user=root --password  --host='.$_LOSP_STORABLE_DATA["config_dbserver"]	= "localhost".'  --add-locks --complete-insert --create-options --lock-tables --result-file='.$var_bash_export_MainDB_file.' --routines --set-charset --triggers  --disable-keys --databases '.$_LOSP_STORABLE_DATA["config_db"].' &&	tar -czf '.$var_bash_export_MainDB_file.'.tar.gz '.$var_bash_export_MainDB_file;

echo "\nlogin: \n ---";
echo "\n MainDB: \n ".$var_bash_MainDB."\n ---";
echo "\n SrequestDB: \n ".$var_bash_SrequestDB."\n ";
echo "\nexport: \n ---";
echo "\n MainDB: \n ".$var_bash_export_MainDB."\n --- \n\n";


//	system($var_bash_MainDB);

?>