MySQL 5.6 Reference Manual Including MySQL NDB Cluster 7.3-7.4 Reference Guide
MySQL applies these rules when various CREATE ... IF
NOT EXISTS
statements are replicated:
Every
CREATE
DATABASE IF NOT EXISTS
statement is replicated,
whether or not the database already exists on the source.
Similarly, every
CREATE TABLE
IF NOT EXISTS
statement without a
SELECT
is replicated, whether
or not the table already exists on the source. This includes
CREATE
TABLE IF NOT EXISTS ... LIKE
. Replication of
CREATE
TABLE IF NOT EXISTS ... SELECT
follows somewhat
different rules; see
Section 17.4.1.7, “Replication of CREATE TABLE ... SELECT Statements”, for
more information.
CREATE EVENT
IF NOT EXISTS
is always replicated in MySQL
5.6, whether or not the event named in the
statement already exists on the source.
See also Bug #45574.