Bug #19862 | SELECT from view with ORDER BY evaluates select expression too many times | ||
---|---|---|---|
Submitted: | 16 May 2006 20:57 | Modified: | 18 Sep 2006 9:54 |
Reporter: | Mats Kindahl | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Views | Severity: | S3 (Non-critical) |
Version: | 5.1 | OS: | Any (ALL) |
Assigned to: | Evgeny Potemkin | CPU Architecture: | Any |
[16 May 2006 20:57]
Mats Kindahl
[17 May 2006 13:01]
Hartmut Holzgraefe
mysqltest test case
Attachment: bug19862.tar.gz (application/x-gzip, text), 975 bytes.
[20 Jul 2006 19:43]
Evgeny Potemkin
The bug can be checked a bit easier: select f1(a) from t2 order by 1;
[24 Jul 2006 13:00]
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/9494
[25 Jul 2006 20:16]
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/9551
[25 Jul 2006 20:31]
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/9553
[2 Aug 2006 18:57]
Evgeny Potemkin
When there is no index defined filesort is used to sort the result of a query. If there is a function in the select list and the result set should be ordered by it's value then this function will be evaluated twice. First time to get the value of the sort key and second time to send its value to a user. This happens because filesort when sorts a table remembers only values of its fields but not values of functions. Fixed in 5.0.25, 5.1.12
[2 Aug 2006 19:05]
Paul DuBois
Noted in 5.0.25, 5.1.12 changelogs.
[14 Aug 2006 20:43]
Konstantin Osipov
Merged into 5.1.12
[15 Sep 2006 16:01]
Lars Thalmann
test case rpl_sp_effects still disabled by this bug
[18 Sep 2006 9:54]
Evgeny Potemkin
Test case enabled in 5.1-opt