Dan,

Try the following

(0) Make sure you have the .frm files backed up

(1) If you have foo.frm, delete foo.* from the data directory, then create
a new MyISAM table.  Doesn't matter what's in it.  E.g., create table foo (x
int).

(2) Copy your saved .frm file back instead of the one just created.

(3) If the table you lost was InnoDB, change the 4th byte of the file
from hex 0C to hex 09.  (This makes it look like a MyISAM .frm)

(4) You should be able to run "show create table foo" from the MySQL client.

HTH

Bill Easton
Lexpar

> Date: Tue, 23 Mar 2004 11:04:49 -0500 (EST)
> From: dan <[EMAIL PROTECTED]>
> To: [EMAIL PROTECTED]
> Subject: using "old" frm files
>
> we had a database blown away (oops) and we still have the old
> .frm files, is there any way to get this structure back?
>
> is there a way to view the contents of the .frm files to
> see how the tables/indexes were setup?
>
> I can't find anything in the docs, faqs, etc.
>
> Dan.


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to