Database Reference
In-Depth Information
Importing Structure and Data
In this chapter, we will learn how to bring back exported data that we create for
backup or transfer purposes. Exported data may also come from authors of other
applications, and could contain the whole foundation structure of these applications
and some sample data.
The current phpMyAdmin version (3.1) can import files containing MySQL
statements (usually having a .sql suffix, but not necessarily so) and CSV files
(comma-separated values, although the separator is not necessarily a comma)
directly. Future versions might be able to import files in more formats. There is also
an interface to the MySQL LOAD DATA INFILE statement, enabling us to load text files
containing data, also called CSV. The binary field upload covered in Chapter 6 can be
said to belong to the import family.
Importing and uploading are synonyms in this context.
The import feature can be accessed from several panels:
The
Import menu available from the homepage, the Database view,
or the Table view
The
Import files menu offered inside the Query window
(as explained in Chapter 12)
A feature was added in version 2.11.0: an import file may contain the DELIMITER
keyword. This enables phpMyAdmin to mimic the mysql command-line interpreter.
The DELIMITER separator is used to delineate the part of the file containing a stored
procedure, as these procedures can themselves contain semicolons.
The default values for the Import interface are defined in $cfg['Import'] .
Before examining the actual import dialog, let's discuss some limits issues.
Search WWH ::




Custom Search