diff options
author | Mattias Jonsson <mattias.jonsson@oracle.com> | 2011-06-13 11:21:54 +0200 |
---|---|---|
committer | Mattias Jonsson <mattias.jonsson@oracle.com> | 2011-06-13 11:21:54 +0200 |
commit | f2f22614fa20e1e033153ad81f44e659bc37c435 (patch) | |
tree | 02e4e1ccf6ada39e4ced2b065a02463b7afbb986 /sql/ha_partition.cc | |
parent | 2a4e1bc9f64f6e6d40ed7f9ade466ef8ce8a5e47 (diff) | |
parent | 8f3bb95a4322c6ca84bfaed52e97950c750fa00d (diff) | |
download | mariadb-git-f2f22614fa20e1e033153ad81f44e659bc37c435.tar.gz |
merge
Diffstat (limited to 'sql/ha_partition.cc')
-rw-r--r-- | sql/ha_partition.cc | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/sql/ha_partition.cc b/sql/ha_partition.cc index 785d118a5f4..5e23891247d 100644 --- a/sql/ha_partition.cc +++ b/sql/ha_partition.cc @@ -3456,9 +3456,13 @@ exit: index) mysql_update does not set table->next_number_field, so we use table->found_next_number_field instead. + Also checking that the field is marked in the write set. */ - if (table->found_next_number_field && new_data == table->record[0] && - !table->s->next_number_keypart) + if (table->found_next_number_field && + new_data == table->record[0] && + !table->s->next_number_keypart && + bitmap_is_set(table->write_set, + table->found_next_number_field->field_index)) { if (!table_share->ha_part_data->auto_inc_initialized) info(HA_STATUS_AUTO); @@ -4110,6 +4114,7 @@ void ha_partition::position(const uchar *record) void ha_partition::column_bitmaps_signal() { handler::column_bitmaps_signal(); + /* Must read all partition fields to make position() call possible */ bitmap_union(table->read_set, &m_part_info->full_part_field_set); } |