I'm working with a database that needs to be populated with time zone data. Turns out that on Unix-based systems, this is rather simple and can be done entirely from the command line. On Windows though (and apparently HP-UX too), you can't use that method. Instead, the MySQL site has downloads here:
I needed this tonight so I grabbed the zip, extracted, and went... wtf...

So maybe I'm dumb, but I expected SQL files I could import via my client or even the command line. I had absolutely no idea what in the heck this was.
Turns out - these are the actual physical file formats used by MySQL to store data. To restore these files, you literally just find your database directory (you can find the root by looking at your MySQL my.ini file) and just copy them in. That's it.
I restarted MySQL just... well just because I figured I'd need to, and it the tables (and data) showed up.
Archived Comments
can't you just dip down into java for those?
Yeah, but this is how the client wanted it though. It's how he did it on his side (on a Mac, I mean, he did it via command line).
The URL doesnt seem to be working. Actually dev.mysql.com doesnt appear to either..which would account for http://dev.mysql.com/downlo... as well I suppose
I swear I didn't break it.
Uh huh
It looks like it working now.
Thanks for fixing the MySql.com site there Ray!
Hi Ray,
I use these at work now and again.
We have some large client db's that are always dumped as .SQL files overnight and then if we need to we just SOURCE them via the command line ( or via a GUI ).
This can take a long time to SOURCE on a local dev PC.
So if you need the data fast you get the DB bloke to give you a NATIVE Dump ( i.e. MYD, MYI and frm files ).
Then it's a straight file copy as you know.
I'll stop rambling now.
@cfjquery
Dave, thanks for sharing that. So - this isn't uncommon then?
It's a DATA thing really, if you have more than 300 tables and one of those is composed of say greater than 1 million records it starts to slow down loads on a local dev PC when trying to SOURCE it locally, the transfer of three files (MYD, MYI and frm) is a known qty (i.e. file size) but SOURCING a DB just takes as long as it takes.Copying the 3 files is much more succinct, however the DB your copying to has to use all the same defaults as the DB you copied from. ( aka it's good too copy your own stuff but it won't really translate if you just try to send people these files).
I shall stop rambling again. Sorry.. it just happens. Oh Well.
We use it to restore backups of DB tables if we ever need them. Quicker than restoring an old database, then mysql dumping and inserting the tables.
.sql files are just instructions for how to interact with the MYD and MYI