Database PHP Programming

PHP: Importing an SQL file via PHP script

Trying to import an SQL file using PHP? Most people will tell you that using PHP function shell_exec to run the MySQL client is your best bet, but what if you simply can’t do it that way? The solution is quite simple, actually, and doesn’t require programming skills beyond the basic file parsing and query executing.