Re: [PHP-DB] Downloading Database?!?!

2003-07-23 Thread David Smith
You can create a batch file like this or if you want it to be in a web
interface much like phpmyadmin, but with your backup scheme you can use
the load data outfile command. This page from the mysql manual describes
both the infile and outfile methods:
http://www.mysql.com/doc/en/LOAD_DATA.html. This will tell you how to
use the syntax for the text files. It will let you do it with tabs,
commas, etc. Then you can use php to create the interface for your new
guy and make it as simple or complex as you like, but you don't even
have to use the filesystem functions to do it this way. Which does make
it a little simpler so that you can plan for 14 weeks of whatever you're
doing.
David Smith

On Wed, 2003-07-23 at 01:32, Stephen March wrote:
> Have you considered using the console-tool,  "mysqldump  "  ?
> You could write a quick script  ... say
> 
> mysqldump -u adminuser -p adminpass --all-databases > backup.sql
> tar -zcvf backup.tar.gz backup.sql
> mv backup.sql  /somepath/backup.sql
> 
> if you're on Winders, a batch file:
> 
> mysqldump -u adminuser -p adminpass --all-databases > backup.sql
> move backup.sql z:\somepath\backup.sql
> 
> If you write a batch script, or shell script, all the "new guy" would 
> have to do is run it. 
> Create a cron job (on linux) or scheduled task (on windows) and the "new 
> guy" just has to figure out the coffee machine  :)
> Food for thought,
> 
> ~Steve
> 
> Brenton Dobell wrote:
> 
> >Hello all,
> >
> >I am developing an Intranet page for my workplace, ATM i use phpmyadmin to
> >do rutine backups ect, this is cool but i am going on long service leave for
> >14 weeks and during that time a new guy will attempt to continue to maintain
> >the site and perform regular "backups"... I tried to show him how to use
> >phpmyadmin but has proved too dificult for him to understand, how can i make
> >a quick script to implement into a page that prompts you to download the
> >entire sctipt in .txt form?? just like php myadmin, and starting tips and
> >hints would be great.
> >
> >
> >Cheers in advance
> >
> >Brenton
> >
> >
> >  
> >
> 
> 
> 
> 
> -- 
> PHP Database Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 



-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP-DB] Downloading Database?!?!

2003-07-22 Thread Stephen March
Have you considered using the console-tool,  "mysqldump  "  ?
You could write a quick script  ... say
mysqldump -u adminuser -p adminpass --all-databases > backup.sql
tar -zcvf backup.tar.gz backup.sql
mv backup.sql  /somepath/backup.sql
if you're on Winders, a batch file:

mysqldump -u adminuser -p adminpass --all-databases > backup.sql
move backup.sql z:\somepath\backup.sql
If you write a batch script, or shell script, all the "new guy" would 
have to do is run it. 
Create a cron job (on linux) or scheduled task (on windows) and the "new 
guy" just has to figure out the coffee machine  :)
Food for thought,

~Steve

Brenton Dobell wrote:

Hello all,

I am developing an Intranet page for my workplace, ATM i use phpmyadmin to
do rutine backups ect, this is cool but i am going on long service leave for
14 weeks and during that time a new guy will attempt to continue to maintain
the site and perform regular "backups"... I tried to show him how to use
phpmyadmin but has proved too dificult for him to understand, how can i make
a quick script to implement into a page that prompts you to download the
entire sctipt in .txt form?? just like php myadmin, and starting tips and
hints would be great.
Cheers in advance

Brenton

 





--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php