0

Hi

I have a MYSQL DB hosted on a Win 2003 server on my LAN
and a Mysql DB on a dedicated (linux) server at our ISP.

I would like to dump a few tables to a .sql file and ftp it to the server and then import the .sql file automatically via a cron job.

I can do the FTP etc. But I am unable to get the exporting and importing to work, not sure why.

I would really appreciate some assistance

5
Contributors
5
Replies
6
Views
5 Years
Discussion Span
Last Post by fabzster
0

I am not an expert in importing and exporting but form what i heard you should use python for this kind of jobs

0

The other option could be to create a web service (or a REST JSON webservice) and have the provider in your ISP that takes the data and store it in your ISP and the client that gives the data in local machines.

0

You should be able to do this easily with a small php script. Make sure that the shebang line at the top is correct (ask your host for the path to php), and that the file containing the code is set as executable. These are problems I've had in the past.

Another problem I've had is that it seems mysql will only accept one command at a time from a script, so you can't send it a whole script, but must send each command individually, or they just won't be carried out.

0

Hi

thanks for the replies

I managed to get my script to work, but the question is can I do this whilst the DB is live every 2 Hrs?

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.