Libing Song wrote:
> Hi Zhenxing,
>
> On Sun, 2010-01-31 at 17:45 +0800, He Zhenxing wrote:
> > Li-Bing.Song@stripped wrote:
> > > #At file:///home/anders/work/bzrwork/worktree5/mysql-pe/ based on
> revid:li-bing.song@stripped
> > >
> > > 3862 Li-Bing.Song@stripped 2010-01-31
> > > Postfix for BUG#48321
> > >
> > > modified:
> > > mysql-test/suite/rpl/r/rpl_mixed_implicit_commit_binlog.result
> > > === modified file
> 'mysql-test/suite/rpl/r/rpl_mixed_implicit_commit_binlog.result'
> > > ---
> a/mysql-test/suite/rpl/r/rpl_mixed_implicit_commit_binlog.result 2009-11-13 00:17:10
> +0000
> > > +++
> b/mysql-test/suite/rpl/r/rpl_mixed_implicit_commit_binlog.result 2010-01-31 08:27:21
> +0000
> > > @@ -213,7 +213,7 @@ Log_name Pos Event_type Server_id End_lo
> > > master-bin.000001 # Query # # BEGIN
> > > master-bin.000001 # Query # # use `test`; INSERT INTO tt_1(ddl_case)
> VALUES (26)
> > > master-bin.000001 # Xid # # COMMIT /* XID */
> > > -master-bin.000001 # Query # # use `test`; ALTER EVENT evt COMMENT 'evt'
> > > +master-bin.000001 # Query # # use `test`; ALTER DEFINER=`root`@`localhost`
> EVENT evt COMMENT 'evt'
> >
> > It look that there is a problem in your patch for this bug for ALTER
> > EVENT.
> >
> > In the above example, the original alter event statement does not
> > include definer=CURRENT_USER, so definer should not be included in the
> > binlogged query.
> >
> > Please check this and push a fix ASAP if confirmed. Thank you!
> I think it is ok, for the definer is always assigned as current user, if
> 'ALTER EVENT' without 'DEFINER' option.
>
Good, thank you for checking on this!
> The following is a test case for that.
>
> source include/master-slave.inc;
> CREATE USER 'slb'@'localhost';
>
> --echo
> CREATE DEFINER='slb'@'localhost' EVENT evt ON SCHEDULE EVERY 1 DAY DO
> SELECT 1+1;
> SELECT definer FROM mysql.event where name='evt';
>
> --echo
> ALTER EVENT evt COMMENT 'evt';
> SELECT definer FROM mysql.event where name='evt';
>
> --echo
> ALTER DEFINER='slb'@'localhost' EVENT evt COMMENT 'evt1';
> SELECT definer FROM mysql.event where name='evt';
>
> --echo
> source include/show_binlog_events.inc;
> source include/master-slave-end.inc;
>
>
> >
> > > -e-e-e-e-e-e-e-e-e-e-e- >> << -e-e-e-e-e-e-e-e-e-e-e-
> > >
> > > -b-b-b-b-b-b-b-b-b-b-b- >> << -b-b-b-b-b-b-b-b-b-b-b-
> > >
> >
> >
> >
>
>