Merge neptunus.(none):/home/msvensson/mysql/mysql-5.0

into  neptunus.(none):/home/msvensson/mysql/mysql-5.0-maint


client/mysql.cc:
  Auto merged
client/mysqltest.c:
  Auto merged
mysql-test/mysql-test-run.pl:
  Auto merged
mysql-test/r/date_formats.result:
  Auto merged
mysql-test/r/union.result:
  Auto merged
mysql-test/t/union.test:
  Auto merged
sql/field.cc:
  Auto merged
sql/item.cc:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/item_func.h:
  Auto merged
sql/item_strfunc.cc:
  Auto merged
sql/item_strfunc.h:
  Auto merged
sql/item_subselect.cc:
  Auto merged
sql/item_sum.cc:
  Auto merged
sql/sql_yacc.yy:
  Auto merged
mysql-test/r/func_group.result:
  Merge manually
mysql-test/t/func_group.test:
  Merge manually
This commit is contained in:
unknown 2006-08-03 09:32:58 +02:00
commit ed44a2ee51
113 changed files with 3252 additions and 6530 deletions

View file

@ -377,7 +377,13 @@ Field *Item_sum::create_tmp_field(bool group, TABLE *table,
case INT_RESULT:
return new Field_longlong(max_length,maybe_null,name,table,unsigned_flag);
case STRING_RESULT:
if (max_length/collation.collation->mbmaxlen > 255 && convert_blob_length)
/*
Make sure that the blob fits into a Field_varstring which has
2-byte lenght.
*/
if (max_length/collation.collation->mbmaxlen > 255 &&
max_length/collation.collation->mbmaxlen < UINT_MAX16 &&
convert_blob_length)
return new Field_varstring(convert_blob_length, maybe_null,
name, table,
collation.collation);