Some issues and considerations for importing SQL files to MySQL


English version steps


When importing sql file to MySQL database:


If after importing, you find that Table/Contents is not displayed:

  1. Then first refresh the whole database/table.

  1. If it still doesn’t work, copy the contents of the sql file you imported, then create a new “Query Text Tab”, paste the copied contents and click “Query” (lightning symbol-⚡️), refresh the database, then you will see the contents you imported.

  • Note: Here you add a “use” + “your schema/database name;” at the top of the sql file you import (usually under the comment at the beginning, in front of the first line of code), so you know which database to import to.

中文版本步骤


当导入sql文件到MySQL数据库:


如果导入后发现Table/内容没有显示:

  1. 那么首先刷新整个数据库/表。

  1. 如果还是不行,拷贝你导入的sql文件的所有内容,然后新建一个“查询文本标签页”,粘贴复制的内容然后点击“查询”(闪电符号-⚡️),再刷新一下数据库即可成功。

  • 注意:这里在你导入的sql文件的最上面加一个 “use” +“你的schema/数据库名;“(通常在开头的注释下面,第一行代码的前面),这样就知道要导入到哪个数据库了。

Author: Anti-General
Reprint policy: All articles in this blog are used except for special statements CC BY 4.0 reprint policy. If reproduced, please indicate source Anti-General !
R
Comment
  TOC