Encountered a need to import the data table from the local MySQL to the server MySQL problem, in the online search, did not find that the operation is very clear, many operations are using the command line to achieve, their own research, found that Navicat has its own import and export functions, it can be easier to implement the function.
Target: Import dozens of tables from MySQL database A of machine A (itself database A has hundreds of tables) to the B machine's MySQL B database. (all of MySQL's operations are done in Navicat)
The first step: in MySQL on a machine to create a new database C, directly in the Navicat Ctrl-Select all the tables to be exported, right-click Copy, do not select Copy table, choose Copy, and then click on the new Database C table, the right side should be empty, directly in the blank right-click Paste, All the tables prepared for export are copied to the new database C
Second step: In database C right-click: Dump the SQL file, and then select the location to save, this time the generated is a. sql file, copy this. sql file to target machine B (U disk or useful drop)
Step three: In the target machine B MySQL (of course, NAVICAT) Select target database B, select the table, then right-click on the right margin, select "Run SQL File", and then select the copy of the. sql file, everything is OK
Finally can change the name of the table according to their own needs, in fact, the first step to create a new database is the main reason is that I do not export all the tables in the database, just need dozens of of the table, so you need to use a new database to copy the tables need to be stored separately, and so the import completed the transfer database C deleted the
Navicat from MySQL guide complete table (including table structure and data) to another machine's MySQL