Spec-Zone .ru
спецификации, руководства, описания, API
|
The following statements support use of the CURRENT_USER()
function to take the place of the name of (and, possibly, the host
for) an affected user or a definer; in such cases, CURRENT_USER()
is expanded where and as needed:
When CURRENT_USER()
or CURRENT_USER
is
used as the definer in any of the statements CREATE
FUNCTION
, CREATE
PROCEDURE
, CREATE TRIGGER
,
CREATE
EVENT
, CREATE VIEW
, or ALTER
VIEW
when binary logging is enabled, the function reference is expanded before it is written to
the binary log, so that the statement refers to the same user on both the master and the slave when the
statement is replicated. CURRENT_USER()
or CURRENT_USER
is
also expanded prior to being written to the binary log when used in DROP USER
, RENAME
USER
, GRANT
, REVOKE
,
or ALTER
EVENT
.