List:Commits« Previous MessageNext Message »
From:Sergei Golubchik Date:August 8 2007 12:10pm
Subject:Re: bk commit into 5.1 tree (antony:1.2569) BUG#10516
View as plain text  
Hi!

On Aug 03, antony@stripped wrote:
> ChangeSet@stripped, 2007-08-03 09:14:49-07:00, antony@stripped +20 -0
>   Bug#10516
>     "getopt_ull_limit_value() does not show warnings or errors"
>     Alter code so that when getopt_ull_limit_value() is used, there
>     are checks performed to validate that the value is in range and
>     to emit errors or warnings accordingly.
>     New test: strict_variables
> 
> diff -Nrup a/mysql-test/r/cache_innodb.result b/mysql-test/r/cache_innodb.result
> --- a/mysql-test/r/cache_innodb.result	2006-11-21 12:32:49 -08:00
> +++ b/mysql-test/r/cache_innodb.result	2007-08-03 09:14:42 -07:00
> @@ -135,6 +135,8 @@ SHOW VARIABLES LIKE 'have_query_cache';
>  Variable_name	Value
>  have_query_cache	YES
>  SET GLOBAL query_cache_size = 200000;
> +Warnings:
> +Warning	1264	Out of range value for column 'query_cache_size' at row 0

It's not out of range. It is adjusted to be a multiple of 1024.
Same below in many cases. I don't know if it deserves a warning or an
error, but if it does - not this one for sure.

>  flush status;
>  SET @@autocommit=1;
>  SET SESSION STORAGE_ENGINE = InnoDB;
> diff -Nrup a/mysql-test/t/strict_variables.test b/mysql-test/t/strict_variables.test
> --- /dev/null	Wed Dec 31 16:00:00 196900
> +++ b/mysql-test/t/strict_variables.test	2007-08-03 09:14:45 -07:00
> @@ -0,0 +1,135 @@
> +# Testing of "strict" mode
> +
> +set @org_mode=@@sql_mode;
> +set @@sql_mode='ansi,traditional';
> +select @@sql_mode;
> +
> +# testing class sys_var_ulonglong_ptr
...

good!

please add also a test when there're two variables assigned in one
statement. Few different combonations, for example, the first is within
range, the other is not. And SELECT to ensure than neither was assigned.

And do you use thd->row_count ?

Regards / Mit vielen GrЭssen,
Sergei

-- 
   __  ___     ___ ____  __
  /  |/  /_ __/ __/ __ \/ /   Sergei Golubchik <serg@stripped>
 / /|_/ / // /\ \/ /_/ / /__  Principal Software Developer
/_/  /_/\_, /___/\___\_\___/  MySQL GmbH, Radlkoferstr. 2, D-81373 MЭnchen
       <___/                  GeschДftsfЭhrer: Kaj ArnЖ - HRB MЭnchen 162140
Thread
bk commit into 5.1 tree (antony:1.2569) BUG#10516antony3 Aug
  • Re: bk commit into 5.1 tree (antony:1.2569) BUG#10516Sergei Golubchik8 Aug