summaryrefslogtreecommitdiff
path: root/sql/item_sum.cc
diff options
context:
space:
mode:
authorunknown <monty@mysql.com>2004-08-26 18:26:38 +0300
committerunknown <monty@mysql.com>2004-08-26 18:26:38 +0300
commit44b2807e4bb2383525c3abfd9ad896114dec0796 (patch)
treec7d296d78817781f8a0bdd6d65ced41030de842c /sql/item_sum.cc
parent92dfd1bf9a3cc1b2ae720363295acf633b1e7271 (diff)
downloadmariadb-git-44b2807e4bb2383525c3abfd9ad896114dec0796.tar.gz
Portability fixes
Fixed bug in end space handle for WHERE text_column="constant" heap/hp_hash.c: Optimzations (no change of logic) libmysql/libmysql.c: Added missing casts (portability fix) myisam/mi_key.c: Changed macro to take arguments and not depend on local variables Simple indentation fixes ? mysql-test/r/connect.result: Added test for setting empty password mysql-test/r/create_select_tmp.result: TYPE -> ENGINE mysql-test/r/ctype_utf8.result: Combine drop's mysql-test/r/endspace.result: Added more tests to test end space behaviour mysql-test/r/having.result: Added missing DROP TABLE mysql-test/r/type_blob.result: Added more tests to ensure that fix for BLOB usage is correct mysql-test/r/type_timestamp.result: Add test from 4.0 mysql-test/t/connect.test: Added test for setting empty password mysql-test/t/create_select_tmp.test: TYPE -> ENGINE mysql-test/t/ctype_utf8.test: Combine drop's mysql-test/t/endspace.test: Added more tests to test end space behaviour mysql-test/t/having.test: Added missing DROP TABLE mysql-test/t/type_blob.test: Added more tests to ensure that fix for BLOB usage is correct mysql-test/t/type_timestamp.test: Add test from 4.0 sql/field.cc: Removed not used variable Portability fix (cast) Simplified Field_str::double() Simple indentation cleanups sql/field.h: Removed not needed class variable sql/item_cmpfunc.cc: Indentation fix sql/item_strfunc.cc: Use on stack variable for Item_str_func::val() instead of str_value. This makes it safe to use str_value inside the Item's val function. Cleaned up LEFT() usage, thanks to the above change sql/item_sum.cc: Indentation cleanups sql/protocol.cc: Added missing cast sql/sql_acl.cc: Indentatin cleanups. Added missing cast Simple optimization of get_sort() sql/sql_select.cc: Don't use 'ref' to search on text field that is not of type BINARY (use 'range' instead). The reson is that for 'ref' we use 'index_next_same' to read the next possible row. For text fields, rows in a ref may not come in order, like for 'x', 'x\t' 'x ' (stored in this order) which causes a search for 'column='x ' to fail sql/tztime.cc: Simple cleanup strings/ctype-bin.c: Comment fixes strings/ctype-mb.c: Changed variable names for arguments
Diffstat (limited to 'sql/item_sum.cc')
-rw-r--r--sql/item_sum.cc8
1 files changed, 4 insertions, 4 deletions
diff --git a/sql/item_sum.cc b/sql/item_sum.cc
index cbb4cd41046..0ec8baf97bb 100644
--- a/sql/item_sum.cc
+++ b/sql/item_sum.cc
@@ -1945,13 +1945,12 @@ void Item_func_group_concat::reset_field()
bool
Item_func_group_concat::fix_fields(THD *thd, TABLE_LIST *tables, Item **ref)
{
+ uint i; /* for loop variable */
DBUG_ASSERT(fixed == 0);
if (save_args_for_prepared_statement(thd))
return 1;
- uint i; /* for loop variable */
-
if (!thd->allow_sum_func)
{
my_error(ER_INVALID_GROUP_FUNC_USE,MYF(0));
@@ -1971,7 +1970,7 @@ Item_func_group_concat::fix_fields(THD *thd, TABLE_LIST *tables, Item **ref)
if (args[i]->fix_fields(thd, tables, args + i) || args[i]->check_cols(1))
return 1;
if (i < arg_count_field)
- maybe_null |= args[i]->maybe_null;
+ maybe_null|= args[i]->maybe_null;
}
result_field= 0;
@@ -2048,7 +2047,8 @@ bool Item_func_group_concat::setup(THD *thd)
of a record instead of a pointer of one.
*/
if (!(table=create_tmp_table(thd, tmp_table_param, all_fields,
- (ORDER*) 0, 0, TRUE,select_lex->options | thd->options,
+ (ORDER*) 0, 0, TRUE,
+ select_lex->options | thd->options,
HA_POS_ERROR,(char *) "")))
DBUG_RETURN(1);
table->file->extra(HA_EXTRA_NO_ROWS);