Commit 4ea9a3d5 authored by unknown's avatar unknown

Merge spetrunia@bk-internal.mysql.com:/home/bk/mysql-5.0-opt

into  mysql.com:/home/psergey/mysql-5.0-bug31450


sql/item.cc:
  Auto merged
mysql-test/r/type_decimal.result:
  Post-merge fixes
mysql-test/t/type_decimal.test:
  Post-merge fixes
parents fa0e1d6b 53dac1ee
......@@ -811,5 +811,14 @@ insert into t1 values (-0.123456,0.123456);
select group_concat(f1),group_concat(f2) from t1;
group_concat(f1) group_concat(f2)
-0.123456 0.123456
create table t1 (
ua_id decimal(22,0) not null,
ua_invited_by_id decimal(22,0) default NULL,
primary key(ua_id)
);
insert into t1 values (123, NULL), (456, NULL);
this must not produce error 1048:
select * from t1 where ua_invited_by_id not in (select ua_id from t1);
ua_id ua_invited_by_id
drop table t1;
End of 5.0 tests
......@@ -4551,7 +4551,7 @@ int Item::save_in_field(Field *field, bool no_conversions)
my_decimal decimal_value;
my_decimal *value= val_decimal(&decimal_value);
if (null_value)
return set_field_to_null(field);
return set_field_to_null_with_conversions(field, no_conversions);
field->set_notnull();
error=field->store_decimal(value);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment