Below is the list of changes that have just been committed into a local
4.1 repository of monty. When monty does a push these changes will
be propagated to the main repository and, within 24 hours after the
push, to the public repository.
For information on how to access the public repository
see http://dev.mysql.com/doc/mysql/en/installing-source-tree.html
ChangeSet
1.2119 05/03/16 01:15:45 monty@stripped +4 -0
Partly reverty back patch (in heap-auto-increment-key detection) to ensure that auto_key and auto_key_type are calculated the same way
sql/ha_heap.cc
1.51 05/03/16 01:15:42 monty@stripped +11 -9
Partly reverty back patch to ensure that auto_key and auto_key_type are calculated the same way
mysql-test/mysql-test-run.sh
1.245 05/03/16 01:15:42 monty@stripped +1 -1
made --skip-ndb a synonyme for --skip-ndbcluster
include/heap.h
1.24 05/03/16 01:15:42 monty@stripped +2 -0
Partly reverty back patch to ensure that auto_key and auto_key_type are calculated the same way
heap/hp_create.c
1.17 05/03/16 01:15:42 monty@stripped +1 -2
Partly reverty back patch to ensure that auto_key and auto_key_type are calculated the same way
# This is a BitKeeper patch. What follows are the unified diffs for the
# set of deltas contained in the patch. The rest of the patch, the part
# that BitKeeper cares about, is below these diffs.
# User: monty
# Host: narttu.mysql.com
# Root: /home/my/mysql-4.1
--- 1.16/heap/hp_create.c 2005-03-15 11:32:08 +02:00
+++ 1.17/heap/hp_create.c 2005-03-16 01:15:42 +02:00
@@ -137,8 +137,6 @@
keyinfo->write_key= hp_write_key;
keyinfo->hash_buckets= 0;
}
- if ((keyinfo->flag & HA_AUTO_KEY) && create_info->with_auto_increment)
- share->auto_key= i + 1;
}
share->min_records= min_records;
share->max_records= max_records;
@@ -149,6 +147,7 @@
share->keys= keys;
share->max_key_length= max_length;
share->changed= 0;
+ share->auto_key= create_info->auto_key;
share->auto_key_type= create_info->auto_key_type;
share->auto_increment= create_info->auto_increment;
/* Must be allocated separately for rename to work */
--- 1.23/include/heap.h 2005-03-15 11:32:08 +02:00
+++ 1.24/include/heap.h 2005-03-16 01:15:42 +02:00
@@ -181,8 +181,10 @@
LIST open_list;
} HP_INFO;
+
typedef struct st_heap_create_info
{
+ uint auto_key; /* keynr [1 - maxkey] for auto key */
uint auto_key_type;
ulong max_table_size;
ulonglong auto_increment;
--- 1.244/mysql-test/mysql-test-run.sh 2005-03-10 21:31:03 +02:00
+++ 1.245/mysql-test/mysql-test-run.sh 2005-03-16 01:15:42 +02:00
@@ -426,7 +426,7 @@
TMP=`$ECHO "$1" | $SED -e "s;--valgrind-options=;;"`
VALGRIND="$VALGRIND $TMP"
;;
- --skip-ndbcluster)
+ --skip-ndbcluster | --skip-ndb)
USE_NDBCLUSTER=""
EXTRA_MASTER_MYSQLD_OPT="$EXTRA_MASTER_MYSQLD_OPT $1"
EXTRA_SLAVE_MYSQLD_OPT="$EXTRA_SLAVE_MYSQLD_OPT $1"
--- 1.50/sql/ha_heap.cc 2005-03-15 11:32:08 +02:00
+++ 1.51/sql/ha_heap.cc 2005-03-16 01:15:42 +02:00
@@ -446,7 +446,6 @@
HA_KEYSEG *seg;
char buff[FN_REFLEN];
int error;
- bool found_real_auto_increment= 0;
for (key= parts= 0; key < table_arg->keys; key++)
parts+= table_arg->key_info[key].key_parts;
@@ -507,20 +506,23 @@
seg->null_bit= 0;
seg->null_pos= 0;
}
- // We have to store field->key_type() as seg->type can differ from it
- if (field->flags & AUTO_INCREMENT_FLAG)
+ if (field->flags & AUTO_INCREMENT_FLAG &&
+ table_arg->found_next_number_field &&
+ key == table_arg->next_number_index)
+ {
+ /*
+ Store key number and type for found auto_increment key
+ We have to store type as seg->type can differ from it
+ */
+ auto_key= key+ 1;
auto_key_type= field->key_type();
+ }
}
}
- if (table_arg->found_next_number_field)
- {
- keydef[table_arg->next_number_index].flag|= HA_AUTO_KEY;
- found_real_auto_increment= table_arg->next_number_key_offset == 0;
- }
mem_per_row+= MY_ALIGN(table_arg->reclength + 1, sizeof(char*));
HP_CREATE_INFO hp_create_info;
+ hp_create_info.auto_key= auto_key;
hp_create_info.auto_key_type= auto_key_type;
- hp_create_info.with_auto_increment= found_real_auto_increment;
hp_create_info.auto_increment= (create_info->auto_increment_value ?
create_info->auto_increment_value - 1 : 0);
hp_create_info.max_table_size=current_thd->variables.max_heap_table_size;
| Thread |
|---|
| • bk commit into 4.1 tree (monty:1.2119) | monty | 16 Mar |