Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I just wanted to check on the replication setup I've got working. The plan was to replicate just one database, so per the MySQL documentation I used the replicate-do-db flag in my MySQL configuration. However per the documentation it says it won't work if your code uses "db.table" format of inserts...

Note that this does not replicate cross-database statements such as UPDATE some_db.some_table SET foo='bar' while having selected a different database or no database.

So, does my combination of the replicate-do-db flag AND the replicate-wild-do-table flag fix this?

replicate-do-db = replicate_me
replicate-wild-do-table = replicate_me.%

I was just wondering, as the replication works as needed.

share|improve this question

1 Answer 1

up vote 2 down vote accepted

It's not that all db.table INSERTs won't work, it's that cross-database ones won't (see the example in the doc page you link to). Your replication probably works because you're not doing any cross-database INSERTs; most people don't.

replicate-wild-do-table won't change anything for this purpose.

share|improve this answer
    
Ah! Cheers for the clarification. –  Coops Aug 7 '09 at 19:09

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.