diff options
author | unknown <evgen@moonbone.local> | 2005-06-22 04:45:10 +0400 |
---|---|---|
committer | unknown <evgen@moonbone.local> | 2005-06-22 04:45:10 +0400 |
commit | 401fa3cb4b47e2eee663058905a4430104c9b75f (patch) | |
tree | 8250cd82d602c34a867dd2c7154f4429f3aa4f29 /sql/item.h | |
parent | 04f6f63dd8bdcb4e0d5e7cc6b2200a87eff037fe (diff) | |
download | mariadb-git-401fa3cb4b47e2eee663058905a4430104c9b75f.tar.gz |
Fix bug#11298 insert into select from VIEW produces incorrect result
when using ORDER BY
Insert were inserting data from last record fetched instead of inserting from
temporary table.
Make Item_ref to save data from result_field if it's available rather then
from *ref on save_in_field() call.
sql/item.h:
Fix bug#11298 insert into select from VIEW produces incorrect result when using ORDER BY
sql/item.cc:
Fix bug#11298 insert into select from VIEW produces incorrect result when using ORDER BY
mysql-test/r/view.result:
Test case for bug#11298 insert into select from VIEW produces incorrect result when using ORDER BY
mysql-test/t/view.test:
Test case for bug#11298 insert into select from VIEW produces incorrect result when using ORDER BY
Diffstat (limited to 'sql/item.h')
-rw-r--r-- | sql/item.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/sql/item.h b/sql/item.h index de292279e06..856434ab626 100644 --- a/sql/item.h +++ b/sql/item.h @@ -1343,8 +1343,7 @@ public: bool send(Protocol *prot, String *tmp); void make_field(Send_field *field) { (*ref)->make_field(field); } bool fix_fields(THD *, struct st_table_list *, Item **); - int save_in_field(Field *field, bool no_conversions) - { return (*ref)->save_in_field(field, no_conversions); } + int save_in_field(Field *field, bool no_conversions); void save_org_in_field(Field *field) { (*ref)->save_org_in_field(field); } enum Item_result result_type () const { return (*ref)->result_type(); } enum_field_types field_type() const { return (*ref)->field_type(); } |