-
-
Notifications
You must be signed in to change notification settings - Fork 139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bug: Update multiple values does not work with WHERE IN clause #781
Comments
davidshiz
added
prio: high
High priority
PR-testing
B-testing
Testing tools and infrastructure
and removed
PR-testing
prio: high
High priority
labels
Oct 24, 2022
ACK |
ACK |
After the predicate is pushed down, no data is obtained(gdb) p push_down_result[0].attrs[1][0].no_obj
$15 = 0
(gdb) p push_down_result[0].attrs[1][0].buffer
$16 = (void *) 0x0
(gdb) bt
#0 Tianmu::handler::ha_tianmu::set_cond_iter (this=0x7f291401c6b0) at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/storage/tianmu/handler/ha_tianmu.cpp:1434
#1 0x0000000002d76464 in Tianmu::handler::ha_tianmu::cond_push (this=0x7f291401c6b0, a_cond=0x7f291401a220)
at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/storage/tianmu/handler/ha_tianmu.cpp:1511
#2 0x00000000022c9298 in init_read_record (info=0x7f2b04fceb90, thd=0x7f2914014970, table=0x7f291401d590, qep_tab=0x7f2b04fce978, use_record_cache=0, print_error=true, disable_rr_cache=false)
at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/sql/records.cc:360
#3 0x000000000245da20 in mysql_update (thd=0x7f2914014970, fields=..., values=..., limit=18446744073709551615, handle_duplicates=DUP_ERROR, found_return=0x7f2b04fced68, updated_return=0x7f2b04fced60)
at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/sql/sql_update.cc:781
#4 0x000000000246401b in Sql_cmd_update::try_single_table_update (this=0x7f291401a450, thd=0x7f2914014970, switch_to_multitable=0x7f2b04fcee0f)
at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/sql/sql_update.cc:2927
#5 0x00000000024645bb in Sql_cmd_update::execute (this=0x7f291401a450, thd=0x7f2914014970) at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/sql/sql_update.cc:3058
#6 0x00000000023aa9b7 in mysql_execute_command (thd=0x7f2914014970, first_level=true) at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/sql/sql_parse.cc:3655
#7 0x00000000023b07c1 in mysql_parse (thd=0x7f2914014970, parser_state=0x7f2b04fcff90) at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/sql/sql_parse.cc:5655
#8 0x00000000023a5758 in dispatch_command (thd=0x7f2914014970, com_data=0x7f2b04fd0730, command=COM_QUERY) at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/sql/sql_parse.cc:1495
#9 0x00000000023a4599 in do_command (thd=0x7f2914014970) at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/sql/sql_parse.cc:1034
#10 0x00000000024d5db7 in handle_connection (arg=0x8a807f0) at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/sql/conn_handler/connection_handler_per_thread.cc:313
#11 0x0000000002ba3100 in pfs_spawn_thread (arg=0x84560f0) at /home/jenkins/workspace/stonedb5.7-zsl-centos7.9-75-133/storage/perfschema/pfs.cc:2197
#12 0x00007f2b0f6871ca in start_thread () from /lib64/libpthread.so.0
#13 0x00007f2b0c9d9e73 in clone () from /lib64/libc.so.6
|
14 tasks
mergify bot
pushed a commit
that referenced
this issue
Dec 9, 2022
Cause of error: Update multiple values does not work with WHERE IN clause Update multiple values does not work with where in clause. Predicate push-down from TIANMU is used, and this process works fine. But when you get the direct result, it is not compatible with TIANMU's dimen_group concrete type. In the execution of a predicate push-down, must get the Filter so that the execution of the follow-up to value, namely DimensionGroupFilter, but the current statement USES the materialized DimensionGroupMaterialized operation Solution Strategy: If the query is executed by a predicate pushdown, materialization is not enabled What remains: When no materialization operation is used in predicate push-down, the impact on query performance of predicate push-down needs to be cross-checked against benchmarks
konghaiya
pushed a commit
to konghaiya/stonedb
that referenced
this issue
Mar 7, 2023
Cause of error: Update multiple values does not work with WHERE IN clause Update multiple values does not work with where in clause. Predicate push-down from TIANMU is used, and this process works fine. But when you get the direct result, it is not compatible with TIANMU's dimen_group concrete type. In the execution of a predicate push-down, must get the Filter so that the execution of the follow-up to value, namely DimensionGroupFilter, but the current statement USES the materialized DimensionGroupMaterialized operation Solution Strategy: If the query is executed by a predicate pushdown, materialization is not enabled What remains: When no materialization operation is used in predicate push-down, the impact on query performance of predicate push-down needs to be cross-checked against benchmarks
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Have you read the Contributing Guidelines on issues?
Please confirm if bug report does NOT exists already ?
Describe the problem
Update multiple values does not work
Expected behavior
the right answer is as follows:
How To Reproduce
CREATE TABLE cs1 (d1 DECIMAL(18), d2 DECIMAL(18));
INSERT INTO cs1 VALUES (125, 125);
INSERT INTO cs1 VALUES (-125, -125);
INSERT INTO cs1 values (99998, 998);
INSERT INTO cs1 values (99999, 999);
select * from cs1;
UPDATE cs1 SET d1=888, d2=777 WHERE d1 in (125, 99999);
select * from cs1;
Environment
Are you interested in submitting a PR to solve the problem?
The text was updated successfully, but these errors were encountered: