1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

logging_ok:

Logging to logging@openlogging.org accepted
func_group.result, func_group.test:
  Added a test case for bug #8893.
opt_sum.cc:
  A misplaced initialization for the returned parameter
  prefix_len in the function find_key_for_maxmin caused
  usage of a wrong key prefix by the min/max optimization
  in cases when the matching index was not the first index
  that contained the min/max field.
This commit is contained in:
igor@linux.local
2005-03-04 20:24:13 -08:00
parent d565920ba2
commit 6d7862aeaf
4 changed files with 58 additions and 1 deletions

View File

@ -624,7 +624,6 @@ static bool find_key_for_maxmin(bool max_fl, TABLE_REF *ref,
{
if (!(field->flags & PART_KEY_FLAG))
return 0; // Not key field
*prefix_len= 0;
TABLE *table= field->table;
uint idx= 0;
@ -637,6 +636,7 @@ static bool find_key_for_maxmin(bool max_fl, TABLE_REF *ref,
KEY_PART_INFO *part,*part_end;
key_part_map key_part_to_use= 0;
uint jdx= 0;
*prefix_len= 0;
for (part= keyinfo->key_part, part_end= part+keyinfo->key_parts ;
part != part_end ;
part++, jdx++, key_part_to_use= (key_part_to_use << 1) | 1)