summaryrefslogtreecommitdiff
path: root/storage/csv
diff options
context:
space:
mode:
authorunknown <istruewing@chilla.local>2007-06-24 16:46:16 +0200
committerunknown <istruewing@chilla.local>2007-06-24 16:46:16 +0200
commit1d71259c10f65b57f28cf35f1addcd6b3cfefaf7 (patch)
tree0a253ea5f55b7614bcf77ee142991debe661532b /storage/csv
parent81d32154d2814b38b68a9a8c8d4c3e27e337ad07 (diff)
parentab8aa930904d15811624fee2f1c886218c4aff3b (diff)
downloadmariadb-git-1d71259c10f65b57f28cf35f1addcd6b3cfefaf7.tar.gz
Merge chilla.local:/home/mydev/mysql-5.1-amain
into chilla.local:/home/mydev/mysql-5.1-axmrg mysql-test/lib/mtr_report.pl: Auto merged
Diffstat (limited to 'storage/csv')
-rw-r--r--storage/csv/ha_tina.cc5
1 files changed, 4 insertions, 1 deletions
diff --git a/storage/csv/ha_tina.cc b/storage/csv/ha_tina.cc
index 6de153c82d7..e503f639d58 100644
--- a/storage/csv/ha_tina.cc
+++ b/storage/csv/ha_tina.cc
@@ -590,6 +590,7 @@ int ha_tina::find_current_row(uchar *buf)
int eoln_len;
my_bitmap_map *org_bitmap;
int error;
+ bool read_all;
DBUG_ENTER("ha_tina::find_current_row");
/*
@@ -601,6 +602,8 @@ int ha_tina::find_current_row(uchar *buf)
local_saved_data_file_length, &eoln_len)) == 0)
DBUG_RETURN(HA_ERR_END_OF_FILE);
+ /* We must read all columns in case a table is opened for update */
+ read_all= !bitmap_is_clear_all(table->write_set);
/* Avoid asserts in ::store() for columns that are not going to be updated */
org_bitmap= dbug_tmp_use_all_columns(table, table->write_set);
error= HA_ERR_CRASHED_ON_USAGE;
@@ -678,7 +681,7 @@ int ha_tina::find_current_row(uchar *buf)
goto err;
}
- if (bitmap_is_set(table->read_set, (*field)->field_index))
+ if (read_all || bitmap_is_set(table->read_set, (*field)->field_index))
(*field)->store(buffer.ptr(), buffer.length(), buffer.charset());
}
next_position= end_offset + eoln_len;