简体   繁体   中英

Exporting a database with phpmyadmin

I followed some instructions over the net how to export your database. When I finished the adminitration I got this txt file:

-- phpMyAdmin SQL Dump


SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";


/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
/*!40101 SET NAMES utf8 */;



DROP TABLE IF EXISTS `article`;
CREATE TABLE IF NOT EXISTS `article` (
  `Title` varchar(200) NOT NULL,
  `article_id` int(11) NOT NULL AUTO_INCREMENT,
  `Article` text NOT NULL,
  `Topics` varchar(100) NOT NULL,
  `author` varchar(100) NOT NULL,
  `page` int(11) NOT NULL,
  `tpage` int(11) NOT NULL,
  PRIMARY KEY (`article_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;






DROP TABLE IF EXISTS `comments`;
CREATE TABLE IF NOT EXISTS `comments` (
  `comments_id` int(11) NOT NULL AUTO_INCREMENT,
  `comment` varchar(1000) NOT NULL,
  `article_id` int(11) NOT NULL,
  `name` varchar(100) NOT NULL,
  PRIMARY KEY (`comments_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 AUTO_INCREMENT=1 ;

Was the export successful. Is it only a textfile.. that I use to pass between computers or upload to a hosting site?

Was the export successful.

It looks like it, at least as far as the table structure is concerned. If the table contained data and you want that to be included, you may need to refine your command line settings. If you need suggestions on how to do that, show how you do the export.

Is it only a textfile.. that I use to pass between computers or upload to a hosting site?

Yes, that's basically the idea of a mySQL dump - that's fine.

If it's big and you need to transport it through the web, mySQL dumps (as long as they don't contain a lot of BLOB data) compress very well, eg using gzip.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM