Well, I'm building a Java program by Netbeans and I need it to back up the whole bank, I have no idea how it does it, I'm new at it.
1 Answer
You can use mysqldump command:
mysqldump --databases mydb > dump.sql
more:
https://dev.mysql.com/doc/refman/5.7/en/mysqldump-sql-format.html
You can call it from Java using:
Process runtimeProcess = Runtime.getRuntime().exec(command);
As described: Simple Backup and Restore for mysql Database from Java