September 2010
Intermediate to advanced
440 pages
9h 23m
English
As we have seen, there are three methods of archiving a MySQL database that a developer can use:
The first and last of these require special permissions on the server. To use Python to manage the backup merely automates the process but still requires you to have access beyond SELECT.
Using MySQLdb, however, we can export the data with only basic privileges. Simply store the results of the SELECT statement into a variable, format it appropriately, and write it to a file.
Read now
Unlock full access