|Info||Screenshots||View files (5)||Download .zip||Reputation||Support forum||Blog|
|Last Updated||Ratings||Unique User Downloads||Download Rankings|
|2010-09-18 (3 years ago)||Not yet rated by the users||Total: 328||All time: 6,340 This week: 1,598|
|data-from-dump 1.0||BSD License||5.0||PHP 5, Databases, Systems administration|
It can parse a MySQL full database and extract the SQL CREATE and INSERT statements just for given tables.
The extracted SQL statements may be executed immediately or saved to a new database dump file.
Sometimes database administrators or programmers need to restore or copy only a few data tables from one server to another, but all they have is a full DUMP file created by standard utilities like 'dump' (for MySQL).
For production systems it can be really HUGE file, so the task seems to be not so simple.
CDataFromDump class aimed to resolve the problem: it parses source dump file and grabs only data for desired table list. These CREATE TABLES and INSERT operators can be instantly executed on connected database or saved into a new SQL file, for editing and/or executing later.
Currently the class has following features:
- During the first scan, it tries to creates "metadata" file for processed dump, so next retrieving jobs will be much faster.
- Grabs only SQL operators for the tables from passed list
CREATE TABLE operators can be executed/included into result SQL file or NOT, according to passed parameters.
Prize: One downloadable e-book of choice by O'Reilly
|mysqldump is a tool for taking backups of MySQL databases. It is part of the distribution of MySQL. It works by generating SQL statements that can be used to recreate the database later.
There are several PHP components that do practically the same as the mysqldump command. However, to restore a backup taken with mysqldump usually you execute all the contained SQL statements, and so you have to recreate the whole database.
This class makes the process of restoring MySQL database backups more convenient. It allows recreating only list of database tables of your choice, instead of recreating all.
It even allows saving the relevant SQL statements into a separate file instead of executing them right away. This way you can recreate only the needed tables in multiple steps, eventually in different machines.
|Version Control||Unique User Downloads||Download Rankings|
|This week:||0||This week:||1,598|