Enable or disable binary logging for the current session. This statement allows administrators to perform operations without replicating them to replicas.
SET [SESSION] sql_log_bin = {0|1}Sets the sql_log_bin system variable, which disables or enables binary logging for the current connection, if the client has the SUPER . The statement is refused with an error if the client does not have that privilege.
Note that setting sql_log_bin=1 has no effect if variable, which enables global binary logging, is not set.
You cannot set sql_log_bin as a global variable.
You can set sql_log_bin as a global variable. This is considered dangerous, though, as it can damage replication.
This page is licensed: GPLv2, originally from