Statements that are unsafe for SBR.
Not all statements which modify data (such as INSERT DELETE, UPDATE, and REPLACE statements)
can be replicated using statement-based replication. Any nondeterministic behavior is difficult
to replicate when using statement-based replication. Examples of such DML (Data Modification
Language) statements include the following:
• A statement that depends on a UDF or stored program that is nondeterministic, since the value
returned by such a UDF or stored program or depends on factors other than the parameters
supplied to it. (Row-based replication, however, simply replicates the value returned by the UDF
or stored program, so its effect on table rows and data is the same on both the master and slave.)
See Section 18.104.22.168, “Replication of Invoked Features”, for more information.
• DELETE and UPDATE statements that use a LIMIT clause without an ORDER BY are
nondeterministic. See Section 22.214.171.124, “Replication and LIMIT”.
• Statements using any of the following functions cannot be replicated properly using statementbased
• LOAD_FILE() 
• UUID() , UUID_SHORT() 
• USER() 
• FOUND_ROWS() 
• SYSDATE()  (unless both the master and the slave are started with the --sysdate-isnow
• GET_LOCK() 
• IS_FREE_LOCK() 
• IS_USED_LOCK() 
• MASTER_POS_WAIT() 
• RAND() 
• RELEASE_LOCK() 
• SLEEP() 
• VERSION() 
However, all other functions are replicated correctly using statement-based replication, including
NOW()  and so forth.
For more information, see Section 126.96.36.199, “Replication and System Functions”.
Statements that cannot be replicated correctly using statement-based replication are logged with a
warning like the one shown here:
090213 16:58:54 [Warning] Statement is not safe to log in statement format.
A similar warning is also issued to the client in such cases. The client can display it using SHOW
... zobacz całą notatkę