When exporting data in a database, how do we export data from a table without exporting all the data in the table? The following example shows how to perform this operation.
Assume that a data table (news) has three fields: id, title, and content. Now you only need to export the content of the content field. You can run the following two commands to complete this task.
Select 'content' from 'News' into outfile "d:/news. SQL ";
Or:
Load data infile 'd:/news. SQL 'into TABLE 'News' ('content ');
Articles you may be interested in
- How to query data of mysql today, yesterday, last 7 days, last 30 days, last month, and last month
- Mysql Server master-slave Database Synchronization Configuration
- MySQL Data Table for Chinese provinces and municipalities
- In php, we use the curl post method to submit data and the get method to obtain webpage data.
- Improves the query speed of millions of data records for MySQL
- How to check MySQL startup time and running time
- Windows cannot start the hardware device because its configuration information (in the Registry) is incomplete or damaged. (Code 19) Solution
- Navicat for mysql remote connection to the mySql database prompt 10061,1045 error Solution