schedule export from mysql to txt-file or csv

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
ballamann
Forum Newbie
Posts: 3
Joined: Tue Sep 06, 2005 1:20 am

schedule export from mysql to txt-file or csv

Post by ballamann »

I need to schedule a job i windows, where i select from a table in mySQL and save the data in a txt or csv file.

; must seperate

I've created a job via php cli, that imports from a txt file, but how do i export it?
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

what's the intention of this export? If it's for backup only, use mysqldump (command line utility)

at any rate, you can use icron or windows' scheduled tasks.
ballamann
Forum Newbie
Posts: 3
Joined: Tue Sep 06, 2005 1:20 am

Post by ballamann »

when i try to use the --tab=dump.txt i get:

can't create/write to file 'test1.txt\table1.sql' <Errcode:2 >

In the help it says something about mysqld deamon has to be installed on the same machine.

Can this be the problem and how do i check if this daemon is installed?
ballamann
Forum Newbie
Posts: 3
Joined: Tue Sep 06, 2005 1:20 am

Post by ballamann »

Oh never mind, i got it to wórk
Post Reply