diff options
author | unknown <evgen@moonbone.local> | 2005-06-22 07:18:42 +0400 |
---|---|---|
committer | unknown <evgen@moonbone.local> | 2005-06-22 07:18:42 +0400 |
commit | a6c7fb455ae6114ae53be58c49d4ef7dbdcd5e3e (patch) | |
tree | da44d153c0a60ceb5f7abf6e089ae58aca2d0274 /mysql-test/t/insert_select.test | |
parent | d785fc60ab902842bf68bfb827120b8015700a98 (diff) | |
download | mariadb-git-a6c7fb455ae6114ae53be58c49d4ef7dbdcd5e3e.tar.gz |
Fix bug #9728 decreased functionality in "on duplicate key update"
Remove changes made by bug fix #8147. They strips list of insert_table_list to
only insert table, which results in error reported in bug #9728.
Added flag to Item to resolve ambigous fields reported in bug #8147.
sql/item.h:
Fix bug#9728 decreased functionality in "on duplicate key update".
sql/item.cc:
Fix bug#9728 decreased functionality in "on duplicate key update"
sql/sql_parse.cc:
Fix bug#9728 decreased functionality in "on duplicate key update"
sql/sql_base.cc:
Fix bug#9728 decreased functionality in "on duplicate key update".
sql/sql_yacc.yy:
Fix bug#9728 decreased functionality in "on duplicate key update"
mysql-test/t/insert_select.test:
Test case for bug#9728 Decreased functionality in "on duplicate key update".
mysql-test/r/insert_select.result:
Test case for bug#9728 Decreased functionality in "on duplicate key update".
Diffstat (limited to 'mysql-test/t/insert_select.test')
-rw-r--r-- | mysql-test/t/insert_select.test | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/mysql-test/t/insert_select.test b/mysql-test/t/insert_select.test index 613c97dc4f1..7402940fa52 100644 --- a/mysql-test/t/insert_select.test +++ b/mysql-test/t/insert_select.test @@ -175,3 +175,17 @@ insert into t1 values (1),(1),(2); insert into t2(ff1) select f1 from t1 on duplicate key update ff2=ff2+1; select * from t2; drop table t1, t2; +# +# BUGS #9728 - 'Decreased functionality in "on duplicate key update"' +# #8147 - 'a column proclaimed ambigous in INSERT ... SELECT .. ON +# DUPLICATE' +# +create table t1 (a int unique); +create table t2 (a int, b int); +insert into t1 values (1),(2); +insert into t2 values (1,2); +select * from t1; +insert into t1 select t2.a from t2 on duplicate key update a= a + t2.b; +select * from t1; +drop table t1; +drop table t2; |