Database dump

Partial or whole extracts of a database are referred to as database dump ( dump = engl. Excerpt for ). Such separations are created for backup or porting the database.

However, a database dump may also contain only the database structure without data. Such a deduction of the database is for example used to convict developments of a project from a test database to a production database.

The form of such an extract differs depending on the application. The product may be a compressed file for a backup or a list of SQL commands.

The advantage lies in the independence of the data. About a dump of the data across different versions can easily play back away back into the database, it is also a porting to another database system possible.

Extract from a MySQL dump

#   # Table structure for table test222   #   CREATE TABLE ' test222 ' (   ' Id' int ( 6 ) unsigned NOT NULL auto_increment,   ' content ' varchar (255 ) default NULL,   PRIMARY KEY ( ' id' )   ) TYPE = MyISAM;   #   # Dumping data for table test222   #   INSERT INTO ' test222 ' VALUES ( 1, ' row1 ');   INSERT INTO ' test222 ' VALUES ( 2, ' line2 '); Here is a table filled with two lines. The dump is thus readable for various SQL -based databases. It was written for MySQL.

Benefits

  • Portability
  • Version independence
  • Human readability

Disadvantages

  • Large dumps ( large files )
  • Databases
219619
de