Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

The method of exporting the whole database using navicat

2025-03-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)05/31 Report--

Editor to share with you the method of using navicat to export the entire database, I believe that most people do not know much about it, so share this article for your reference, I hope you can learn a lot after reading this article, let's go to know it!

First of all, let's make it clear that when navicat exports the database by rollover to a SQL file, if there is a foreign key, it will cause an error during import, so we need to export using data transfer.

Choose to save it as a file.

Advanced options need to be selected

In this way, the exported SQL script is a complete version, and the import in the new database will not report an error.

* if an import error occurs: [Err] 1067-Invalid default value for 'search_time' reports an error because there is a STRICT mode (strict mode) in the mysql5.7 version, and the date value is not allowed to be set to all zero by default in this mode, so to solve this problem, you need to modify the value of sql_mode.

Solution:

Mysql > select @ @ sql_mode;mysql > set sql_mode= (select replace (@ @ sql_mode,'NO_ZERO_IN_DATE,NO_ZERO_DATE',''))

It is useless to finish the change here, because you have to change the global parameters.

Mysql > set @ @ global.sql_mode= (select replace (@ @ global.sql_mode,'NO_ZERO_IN_DATE,NO_ZERO_DATE','')); mysql > select @ @ global.sql_mode

Just import it again.

The above is all the contents of this article entitled "how to export an entire database using navicat". Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report