44 TableList *orig_next_table= context->last_name_resolution_table;
45 context->last_name_resolution_table= context->first_name_resolution_table;
46 bool res= arg->fix_fields(session, &arg);
47 context->last_name_resolution_table= orig_next_table;
52 if (arg->type() == REF_ITEM)
55 if (ref->ref[0]->type() != FIELD_ITEM)
57 my_error(ER_BAD_FIELD_ERROR, MYF(0),
"",
"VALUES() function");
66 assert(arg->type() == FIELD_ITEM);
68 Item_field *field_arg= (Item_field *)arg;
70 if (field_arg->field->getTable()->insert_values.size())
72 Field *def_field= (
Field*) memory::sql_alloc(field_arg->field->size_of());
73 memcpy(
static_cast<void *
>(def_field),
74 static_cast<const void *
>(field_arg->field),
75 field_arg->field->size_of());
76 def_field->move_field_offset((ptrdiff_t)
77 (&def_field->getTable()->insert_values[0] - def_field->getTable()->
record[0]));
84 tmp_field->init(field_arg->field->getTable());