Bug #28701 | SELECTs from VIEWs completely ignore USE/FORCE KEY, allowing invalid statements | ||
---|---|---|---|
Submitted: | 27 May 2007 2:30 | Modified: | 5 Nov 2007 2:43 |
Reporter: | Björn Steinbrink | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Views | Severity: | S3 (Non-critical) |
Version: | 5.0.41, 5.1 | OS: | Any |
Assigned to: | Georgi Kodinov | CPU Architecture: | Any |
[27 May 2007 2:30]
Björn Steinbrink
[27 May 2007 2:40]
Björn Steinbrink
I just noticed that this only happens with the MERGE algorithm, when using the TEMPTABLE algorithm, MySQL correctly complains that there is no such index (as the temporary table has no indexes).
[28 May 2007 9:00]
Sveta Smirnova
Thank you for the report. Verified as described. All versions are affected.
[4 Jun 2007 7:19]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/28018 ChangeSet@1.2506, 2007-06-04 10:18:52+03:00, gkodinov@magare.gmz +4 -0 Bug #28701: Views don't have indexes. So they can't take index hints. Added a check and disabled the usage of hints for views.
[6 Jun 2007 14:59]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/commits/28216 ChangeSet@1.2506, 2007-06-06 17:54:14+03:00, gkodinov@macbook.gmz +3 -0 Bug #28701: Views don't have indexes. So they can't take index hints. Added a check and disabled the usage of hints for views.
[29 Oct 2007 8:43]
Bugs System
Pushed into 5.0.52
[29 Oct 2007 8:46]
Bugs System
Pushed into 5.1.23-beta
[29 Oct 2007 8:50]
Bugs System
Pushed into 6.0.4-alpha
[5 Nov 2007 2:43]
Paul DuBois
Noted in 5.0.52, 5.1.23, 6.0.4 changelogs. Views do not have indexes, so index hints do not apply. Use of index hints when selecting from a view is now disallowed.