Re: wget cron job to dump mysql db to file
| From: | Greg Donald | Date: | Wed, 02 Aug 2000 19:45:40 +0000 |
| Subject: | Re: wget cron job to dump mysql db to file | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-9806@lists.php.net to get a copy of this message | ||
On Wed, 2 Aug 2000, Eric Porter wrote:
> Hello all,
> I have to believe this has been done before, but
> after searching the list, the code exchange and
> webdev sites, and mysql.com I can't find the
> answer.
> I want to execute the command (the current
> mystery) that dumps my table to a file from the
> mysql database. I have it all set up to name the
> file, attach the file to a mimeclass email. My
> intention is to set this page as a wget cron job.
>
> I tried mysqldump, but the command isnt
> available to me. Thanks for info on the command..
wget is for pulling things from the net to your box, not for dumping mysql
tables and mailing them...
Write a simple php script that dumps the mysql database to a file, the
syntax is in the manual. Once you get that working correctly, add a
mail() command to the script to mail the dump file to yourself. Once you
have it working just like your want, setup a cronjob to run the php
script nightly or whatever.
Greg
--
------------------------------------------------------------------------
destiney - (des-ti-ny) - n. 1. deity of all things "html", 2. common
internet addict, 3. lover of late 80's heavy metal music, 4. Activist
for the terminally un-elite; see also - cool guy, des, mr. php...
It's 4:00am, your web site is still up, why are you?
http://destiney.com/
------------------------------------------------------------------------