https://github.com/vukbgit/mysql-tools
tools to handle mysql dbs
https://github.com/vukbgit/mysql-tools
Last synced: 3 months ago
JSON representation
tools to handle mysql dbs
- Host: GitHub
- URL: https://github.com/vukbgit/mysql-tools
- Owner: vukbgit
- Created: 2021-11-08T16:25:54.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2023-10-25T07:48:49.000Z (over 1 year ago)
- Last Synced: 2025-01-08T06:14:41.311Z (5 months ago)
- Language: Shell
- Size: 11.7 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
A set of bash scripts to deal with a MySQL database
## INSTALLATION ##
* clone repository:
`git clone https://github.com/vukbgit/mysql-tools.git`
* setup config file:
`cp .config.template .config`
* edit config file setting:
* db_source: name of the database to start comparison
* db_target: name of the database to be compared to db_source
* user: MySQL user name into scripts
* password: MySQL user password
* host and port if needed## SCRIPTS ##
* `compare.sh`: makes a comparison using mysqldbcompare, unfortunately not useful for automatic datyabase synchronization
* `export.sh [database-name] [table-name]`: dumps a whole database or just a table if second argument provided
* `import.sh -d [database-name] -f [path-to-dump-file]`: imports a database from a dump file
* `create_objects.sh [object-1] [object-2] ...`: shows create sql for tables/views