I have an .mdb file, and I need to inject all its data into MySQL using PHP code. What I do is the following:
// Executa comando via shell para upload do banco no mysql
$scriptEsquema = shell_exec('mdb-schema uploads/arquivo.mdb mysql | grep -v ^DROP | mysql -u usuario meubancodedados');
$scriptInsert = shell_exec('mdb-export -D "%Y-%m-%d %H:%M:%S" -H -I mysql uploads/arquivo.mdb MINHATABELA | mysql -u usuario meubancodedados');
- On my computer it works quietly, but when it goes to a server it does not work anymore.
Would there be another way to do this with PHP? Or something I should do on the server?