Import .sql file via PHP



Does anyone know how to import a .sql dump file into a mysql database using
php. I know how to do it using commandline, mysql < test.sql, but I am
writing an install script, and was wondering if it is possible to do it this
way. If not, do you know of any parser that will do all the importing/table
creation the .sql file defines? Any response is much appreciated.

Thanks,
Jamie


.



Relevant Pages

  • Re: Import .sql file via PHP
    ... > Does anyone know how to import a .sql dump file into a mysql database using ... > php. ... I know how to do it using commandline, mysql < test.sql, but I am ...
    (comp.lang.php)
  • Re: "call to undefined function" mysql_error when adding new rows to table
    ... I have recently set up a mysql database of local pubs, ... when I try to add a new pub I get an error message "call to undefined ... Shouldn't be any PHP problem. ...
    (comp.lang.php)
  • Re: breaking into J2EE: steep curve or wrong approach?
    ... > a MySQL database. ... > I'd like to recode the PHP functionality as either servlets or JSPs. ... You need to understand servlets. ...
    (comp.lang.java.programmer)
  • Re: Executing PHP files on remote web server
    ... Is it possible to move a few of the PHP pages -- the ... from the session variables on our web server, but I'm a C and Java ... You should have the same security concern for your own MySQL database. ... users with IP addresses on our network, ...
    (comp.lang.php)
  • Mysql Search
    ... I am not sure if this is a PHP or MySql problem, ... I have a MySql database which has a field containing a list of words (comma ... The user inputs a search word to an HTML form which then ...
    (alt.php)