Bug #1711 | Error 127 from table handler, unknown cause | ||
---|---|---|---|
Submitted: | 30 Oct 2003 7:54 | Modified: | 11 Dec 2003 6:33 |
Reporter: | Adam Clauss | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: MyISAM storage engine | Severity: | S2 (Serious) |
Version: | 4.0.16 | OS: | Windows (Windows XP/2003) |
Assigned to: | Michael Widenius | CPU Architecture: | Any |
[30 Oct 2003 7:54]
Adam Clauss
[30 Oct 2003 7:55]
Adam Clauss
Queries that will cause the error
Attachment: test.sql (text/plain), 27.67 KiB.
[30 Oct 2003 8:41]
Dean Ellis
The UPDATE statement in the supplied test reports errno 127 on both Windows XP and Linux with 4.0.16. Neither CHECK TABLE nor myisamchk itself find any problems with the table. Thank you
[30 Oct 2003 9:57]
Adam Clauss
I just installed 4.0.15 and can confirm that the problem exists there as well. Was unable to locate 4.0.13 or 4.0.14 for testing.
[11 Dec 2003 6:33]
Michael Widenius
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release. If necessary, you can access the source repository and build the latest available version, including the bugfix, yourself. More information about accessing the source trees is available at http://www.mysql.com/doc/en/Installing_source_tree.html Additional info: The problem is the last update: UPDATE items, items AS items2 SET items.catID = items2.catID, items.name = items2.name, items.id = items2.id, items.description = items2.description, items.added = 1 WHERE items.dupeitem = items2.scriptID; MySQL can't handle the case where you both use and update the same table in the same query in a multi-update statements. Beasue of caching problems MySQL thinks the table is crashed (becasue a row changed unexpectedly) and stops and gives an error. I have now fixed this by disabling the row cache for any tables that are updated. After this the test case passed without any problems. The fix will be in 4.0.17