exec or shell_exec for dumping MySql info?

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • lawrence k

    exec or shell_exec for dumping MySql info?

    I'm trying to figure out how to export info from a Mysql database,
    using PHP to manage the export, as phpMyAdmin manages to do. I'm
    guessing I need to run a shell script that looks like this:

    mysqldump -u username -ppassword database_name FILE.sql

    and I need to call this shell script using one of the functions on this
    page:



    but which?

    Do I use exec?

  • Andy Hassall

    #2
    Re: exec or shell_exec for dumping MySql info?

    On 5 Nov 2006 18:21:16 -0800, "lawrence k" <lkrubner@geoci ties.comwrote:
    >I'm trying to figure out how to export info from a Mysql database,
    >using PHP to manage the export, as phpMyAdmin manages to do. I'm
    >guessing I need to run a shell script that looks like this:
    >
    >mysqldump -u username -ppassword database_name FILE.sql
    >
    >and I need to call this shell script using one of the functions on this
    >page:
    >
    >http://us2.php.net/exec
    >
    >but which?
    >
    >Do I use exec?
    Yes, that'd be a reasonable choice for running an external command like
    mysqldump.

    --
    Andy Hassall :: andy@andyh.co.u k :: http://www.andyh.co.uk
    http://www.andyhsoftware.co.uk/space :: disk and FTP usage analysis tool

    Comment

    Working...