Importing a large .sql database file into MAMP

Home/Technology/Tutorials/Importing a large .sql database file into MAMP

This article written by helped me out so much and is cleanly written I had to re-share it. Full props go to Fatheadesign.

The original article can be found here

If you are struggling to import a larger database using MAMP you may have seen this image below, if you have you now how frustrating this can be.

I can across this when trying to copy my works WordPress install and set up a local server.

Below is copy and pasted directly from



Screen shot 2013-01-11 at 4.50.43 PM

This happens to me quite often, and I finally found a workaround for this within my local MAMP dev environment.

1. Open up the file within the phpmyadmin dir with your favorite code editor. In your local MAMP environment, it should be located here:

Hard Drive » Applications » MAMP » bin »

2. Do a search for the phrase $cfg

[‘UploadDir’] – it’s going to look like this:

$cfg['UploadDir'] = '';

3. Change it to look like this:

$cfg['UploadDir'] = 'upload';

4. Then, within that phpmyadmin dir, create a new folder & name it upload.

5. Take that large .sql file that you’re trying to import, and put it in that new upload folder.

6. Now, solidsthe next time you go to import a database into phpMyAdmin, you’ll see a new dropdown field right below the standard browse area in your “File to Import” section, like this:

Screen shot 2013-01-11 at 5.21.45 PM

Select that dropdown, and your file will show up right there. Hilight the db, and hit “Import” – and you’re golden!

By | 2017-05-15T21:26:53+00:00 April 1st, 2015|Technology, Tutorials|0 Comments

Leave A Comment