Richard Trahan wrote:
I'm running 3.23.54 on Windows 98. I cannot access any tables
of a database which previously worked fine and suddenly broke.
I get Error 1017 errno: 2 from both mysqlcc 0.9.4 and mysqlc.
This error is discussed on this page:
http://dev.mysql.com/doc/mysql/en/ca...ind-table.html
The system complains that it cannot find any of the .MYD files,
although they are clearly there. The file system is perfectly
analogous to other databases in the same tree which work ok.
You could also try the many repair tools and options that come with
MySQL. These are remarkably effective. Try reading the docs for
myisamchk and see if you can repair the table:
http://dev.mysql.com/doc/mysql/en/ta...intenance.html
And the subsections of that page.
I can write a program to recover the MYD files in plain text form
if I knew the file structure, but I can't figure it out.
For what it's worth, the code to access a MYD file is all open-source
and available for download at MySQL.com. I'm referring to the source
code for the MySQL product itself. You could theoretically find the
code within to read and write the MYD file.
However, IMHO it wouldn't be worth the effort to write such a program.
In most cases, your time will be better spent recovering the data from
backups, and recreating any additional data created since your last backup.
If the data is important and irreplaceable, you should always have a
reliable backup procedure in effect to ensure you have usable backups.
Regards,
Bill K.