List:Commits« Previous MessageNext Message »
From:Davi Arnaut Date:December 16 2010 1:10pm
Subject:Re: bzr commit into mysql-trunk branch (Li-Bing.Song:3207) WL#5576
View as plain text  
Hi Libing,

On 12/16/10 10:33 AM, Li-Bing.Song@stripped wrote:
> #At file:///home/anders/Work/bzrwork/wt1/mysql-trunk-wl5576/ based on
> revid:alexander.nozdrin@stripped
>
>   3207 Li-Bing.Song@stripped	2010-12-16
>        WL#5576 Prohibit CREATE TABLE ... SELECT to modify other tables
>
>        In 'CREATE TABLE ... SELECT' statement, SELECT clause could call store
> functions
>        to modify other tables. It made CTS's behavior towards complex and not
>        understandable. It also caused some binlogging problem. So the behavior
> modifying
>        other tables is prohibited in this worklog.
>
>        In this patch, code is added to check if there is any other table owning
> WRITE
>        lock just after all tables have been locked. CREATE TABLE ... SELECT will
> fail
>        and print an error immediately if any other table has WRITE lock.
>
>        BUG#39804 and BUG#55876 are fixed by this worklog.

Nice work. Patch approved given the comments below are addressed.

[..]

> === modified file 'sql/share/errmsg-utf8.txt'
> --- a/sql/share/errmsg-utf8.txt	2010-11-15 16:43:41 +0000
> +++ b/sql/share/errmsg-utf8.txt	2010-12-16 12:33:08 +0000
> @@ -6446,3 +6446,6 @@ ER_RPL_INFO_DATA_TOO_LONG
>     eng "Data for column '%s' too long"
>   ER_CANT_LOCK_RPL_INFO_TABLE
>           eng "You can't use locks with rpl info tables."
> +
> +ER_CANT_UPDATE_USED_TABLE_IN_CREATE_TABLE_SELECT

Suggest to rename to ER_CANT_UPDATE_TABLE_IN_CREATE_TABLE_SELECT.

> +  eng "Can't update table '%-.192s' using a stored function while '%-.192s' is being
> created. CREATE TABLE ... SELECT statement aborted."

The last part "CREATE TABLE ... SELECT statement aborted." is 
unnecessary. Please drop it.

Regards,

Davi
Thread
bzr commit into mysql-trunk branch (Li-Bing.Song:3207) WL#5576Li-Bing.Song16 Dec
  • Re: bzr commit into mysql-trunk branch (Li-Bing.Song:3207) WL#5576Davi Arnaut16 Dec
    • Re: bzr commit into mysql-trunk branch (Li-Bing.Song:3207) WL#5576Libing Song17 Dec