[MDEV-20746] Crash on query with EXISTS Created: 2019-10-04 Updated: 2019-10-06 Resolved: 2019-10-06 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Optimizer |
| Affects Version/s: | 10.4.8 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | Thomas Plant | Assignee: | Unassigned |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Environment: |
CentOS Linux release 7.7.1908 (Core) |
||
| Attachments: |
|
||||||||
| Issue Links: |
|
||||||||
| Description |
|
When we execute the following query the server crashes: SELECT * FROM `users` WHERE ( `role` = 1 OR `role` = 10 ) AND EXISTS ( SELECT * FROM `email_templates` INNER JOIN `users_email` ON `email_templates`.`id` = `users_email`.`email_template_id` WHERE `users`.`id` = `users_email`.`user_id` AND `email_template_id` = 12 ) AND `users`.`deleted_at` IS NULL; If executed with the value of for example 11 (or any other value) in 'email_template_id' the query works. Here the log in MariaDB error file:
I attach zip file with Table and Index description and two files with 'EXPLAIN EXTENDED', first where the query crashes and the second with a working query. |
| Comments |
| Comment by Alice Sherepa [ 2019-10-04 ] |
|
Please, try setting optimizer_switch='rowid_filter=off' as a temporary workaround. |
| Comment by Thomas Plant [ 2019-10-04 ] |
|
Yes, setting optimizer_switch='rowid_filter=off' resolves the issue on our server. Thanks, |
| Comment by Elena Stepanova [ 2019-10-06 ] |
|
Let's then continue tracking it in |