Skip to content

Commit 03a0623

Browse files
committed
cleanup: rename a method
1 parent 46ae210 commit 03a0623

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

sql/field.h

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1393,7 +1393,7 @@ class Field: public Value_source
13931393
- If field is char/varchar/.. and is not part of write set.
13941394
TRUE - If field is char/varchar/.. and is part of write set.
13951395
*/
1396-
virtual bool is_updatable() const { return FALSE; }
1396+
virtual bool is_varchar_and_in_write_set() const { return FALSE; }
13971397

13981398
/* Check whether the field can be used as a join attribute in hash join */
13991399
virtual bool hash_join_is_possible() { return TRUE; }
@@ -1702,7 +1702,7 @@ class Field_longstr :public Field_str
17021702
int store_decimal(const my_decimal *d);
17031703
uint32 max_data_length() const;
17041704

1705-
bool is_updatable() const
1705+
bool is_varchar_and_in_write_set() const
17061706
{
17071707
DBUG_ASSERT(table && table->write_set);
17081708
return bitmap_is_set(table->write_set, field_index);
@@ -3204,7 +3204,8 @@ class Field_blob :public Field_longstr {
32043204
int store_field(Field *from)
32053205
{ // Be sure the value is stored
32063206
from->val_str(&value);
3207-
if (table->copy_blobs || (!value.is_alloced() && from->is_updatable()))
3207+
if (table->copy_blobs ||
3208+
(!value.is_alloced() && from->is_varchar_and_in_write_set()))
32083209
value.copy();
32093210
return store(value.ptr(), value.length(), from->charset());
32103211
}

0 commit comments

Comments
 (0)