Page 1 of 1
Incremental backups of a table
Posted: Mon Mar 19, 2012 5:29 am
by cjoly
Greetings from France,
I have a mysql table called 'virtualshowtime' that is updated through a form. I would like to be able to create backups of this table e.g.'virtualshowtime_backup1', 'virtualshowtime_backup2', 'virtualshowtime_backup3', etc. each time the form is submitted and before the 'virtualshowtime' table is updated with data.
Thanks in advance for your help and best regards from Paris,
Christophe
Re: Incremental backups of a table
Posted: Fri Mar 23, 2012 4:23 pm
by mecha_godzilla
Hi,
Do you need these backups to be created as MySQL binaries or are you just retrieving records from the the database and saving them as text files? If you want to create MySQL binaries you might need to create a 'trigger' that creates a backup each time a new record is added to the database, but you'll need to make sure this isn't taking too long to run because the backup has to complete before the new record can be added. You also need to consider issues such as record locking (because the backups might become inconsistent if two people are trying to add a new record at roughly the same time) and whether your default MySQL account has the necessary privileges to create backups.
If you need any specific help with MySQL then you might want to post a question in the Databases forum on this site.
HTH,
Mecha Godzilla
Re: Incremental backups of a table
Posted: Fri Mar 23, 2012 4:59 pm
by califdon
Would you mind explaining why you feel you need to do this? Ordinarily this is not required, which is why I'm asking. You may have a good reason, but knowing what it is would enable us to give you better advice.
Re: Incremental backups of a table
Posted: Fri Mar 23, 2012 5:06 pm
by mecha_godzilla
I agree with califdon - I've never heard of a requirement for something like this before because it would be too processor-intensive for big databases, so explaining what you're trying to do would help.
M_G