Magento database imports and exports to process foreign keys. After testing, the foreign key can be removed smoothly with this section added.
Magento database imports and exports to process foreign keys. After testing, the foreign key can be removed smoothly with this section added.
Magento database imports and exports to process foreign keys.
After testing, the foreign key can be removed smoothly with this section added.
Header
/*! 40101 SET @ OLD_CHARACTER_SET_CLIENT = @ CHARACTER_SET_CLIENT */;
/*! 40101 SET @ OLD_CHARACTER_SET_RESULTS = @ CHARACTER_SET_RESULTS */;
/*! 40101 SET @ OLD_COLLATION_CONNECTION = @ COLLATION_CONNECTION */;
/*! 40101 set names utf8 */;
/*! 40103 SET @ OLD_TIME_ZONE = @ TIME_ZONE */;
/*! 40103 SET TIME_ZONE = '+ '*/;
/*! 40014 SET @ OLD_UNIQUE_CHECKS =@ UNIQUE_CHECKS, UNIQUE_CHECKS = 0 */;
/*! 40014 SET @ OLD_FOREIGN_KEY_CHECKS = @ FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS = 0 */;
/*! 40101 SET @ OLD_ SQL _MODE = @ SQL _MODE, SQL _MODE = 'no _ AUTO_VALUE_ON_ZERO '*/;
/*! 40111 SET @ OLD_ SQL _NOTES = SQL _notes, SQL _NOTES = 0 */;
/*! 40101 SET @ OLD_CHARACTER_SET_CLIENT = @ CHARACTER_SET_CLIENT */;
/*! 40101 SET @ OLD_CHARACTER_SET_RESULTS = @ CHARACTER_SET_RESULTS */;
/*! 40101 SET @ OLD_COLLATION_CONNECTION = @ COLLATION_CONNECTION */;
Tail
/*! 40101 SET SQL _MODE = @ OLD_ SQL _MODE */;
/*! 40014 SET FOREIGN_KEY_CHECKS = @ OLD_FOREIGN_KEY_CHECKS */;
/*! 40014 SET UNIQUE_CHECKS = @ OLD_UNIQUE_CHECKS */;
/*! 40101 SET CHARACTER_SET_CLIENT = @ OLD_CHARACTER_SET_CLIENT */;
/*! 40101 SET CHARACTER_SET_RESULTS = @ OLD_CHARACTER_SET_RESULTS */;
/*! 40101 SET COLLATION_CONNECTION = @ OLD_COLLATION_CONNECTION */;
/*! 40111 SET SQL _NOTES = @ OLD_ SQL _NOTES */;
Method 2
Disable related database keyword relationships forcibly:
SET @ OLD_CHARACTER_SET_CLIENT = @ CHARACTER_SET_CLIENT;
SET @ OLD_CHARACTER_SET_RESULTS = @ CHARACTER_SET_RESULTS;
SET @ OLD_COLLATION_CONNECTION = @ COLLATION_CONNECTION;
Set names utf8;
SET @ OLD_UNIQUE_CHECKS =@ UNIQUE_CHECKS, UNIQUE_CHECKS = 0;
SET @ OLD_FOREIGN_KEY_CHECKS = @ FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS = 0;
SET @ OLD_ SQL _MODE = @ SQL _MODE, SQL _MODE = 'no _ AUTO_VALUE_ON_ZERO ';
SET @ OLD_ SQL _NOTES = SQL _notes, SQL _NOTES = 0;
Restore related database keyword relationships:
SET SQL _MODE = @ OLD_ SQL _MODE;
SET FOREIGN_KEY_CHECKS = @ OLD_FOREIGN_KEY_CHECKS;
SET UNIQUE_CHECKS = @ OLD_UNIQUE_CHECKS;
SET CHARACTER_SET_CLIENT = @ OLD_CHARACTER_SET_CLIENT;
SET CHARACTER_SET_RESULTS = @ OLD_CHARACTER_SET_RESULTS;
SET COLLATION_CONNECTION = @ OLD_COLLATION_CONNECTION;
SET SQL _NOTES = @ OLD_ SQL _NOTES;
Both methods are OK to remove the foreign key from the mysql database.
,