I originally came across this issue when i was trying to work with WAMP, a local phpmyadmin server allowing me to work with different websites including drupal on my computer instead of a web host.
I ran into some issues. First the sql file did not load. I changed settings in php.ini file which did not work. Then i used this $cfg['UploadDir'] hack which put a drop down to the directory with the sql file in the "import" tab of the phpmyadmin.
The full code was $cfg['UploadDir'] = "/demo"
This worked except one value in the sql file was too long and caused another error.
In the phpmyadmin import tab i entered the number 80 in the text box that says "0". This "skips" the starting rows where the long fields may be. This worked.
When trying to view the website i ran into connection problems which i had to fix at sites/default settings.php. Remember, this was a drupal website.
In the settings i entered the correct database information and it worked. Although i got a white screen No content. At first i though it was a connection issue but that wasn't the problem. Long story short if you are using WAMP server for local web building, then you need to go to Apache > Modules and turn on the rewrite_module. This is from the WAMP Apache settings you will see by clicking on the "w" icon in your task bar.
This kind of fixed the issue but i was getting errors and still could not see the full website. But i could see the 'admin' section a little.
Long story short i tried a new installation of drupal and everything worked perfectly. My existing drupal website was faulty and caused the issues. Otherwise if i was building a new website everything would have came out clean.
I have given up on trying to get this specific website to work on my local machine, although i learned an awesome new technique for building websites offline. I will use wamp server and local hosting for probably all my life so this experience was kind of worth it.