Can you configure the table structure of two databases to maintain Synchronize in the same link property of mysql?

in the same MySQL link attribute, it can also be said to be the same database. Can you configure all the table structures of one database and Synchronize of another database?

is similar to master-slave Synchronize, but only needs Synchronize data structure, not Synchronize data.

in addition, it is in the same link property, not multiple links.

my requirements are:

I have a project already online, which is my own private project. I often change the database table structure offline. I now hope that the online program connects to one database, and my development environment links to another database. Any changes to the database of my development environment will automatically send Synchronize to the database of the online environment, and the two libraries use the same database link.


MySQL does not have a trigger at the DDL level, so it is difficult to implement it in MySQL , but you can use an external script

.

automatic synchronization table structure of MySql

see if it can meet the requirements

=

the original question said that the same link was supposed to refer to two libraries in the same instance, but the original requirement was to synchronize the table structure between the two instances

this kind of requirement is convenient with tools. In addition to the above, there is another

.

mysql-schema-sync

ps: testing Synchronize to production, there is some danger.


Why don't you tell me what you want to do? See if there are any other ways to implement

MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1e3bf4b-4466b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1e3bf4b-4466b.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?