I exported all the civi tables from one database and saved as a sql file, including a droptable statement. I then tried to import the data into a fresh site with brand new civi installation. The import fails with a foreign key constraint failure. When that failed I tried to import a sql file with data only, no structure, no drop table. Also failed with
1st SQL query (with structure & data):
-- --------------------------------------------------------
--
-- Table structure for table `civicrm_action_mapping`
--
DROP TABLE IF EXISTS `civicrm_action_mapping` ;
MySQL said: Documentation
#1217 - Cannot delete or update a parent row: a foreign key constraint fails
2nd SQL Query (data only)
-- Dumping data for table `civicrm_acl_entity_role`
--
INSERT INTO `civicrm_acl_entity_role` ( `id` , `acl_role_id` , `entity_table` , `entity_id` , `is_active` )
VALUES ( 1, 3, 'civicrm_group', 1, 1 ) , ( 2, 1, 'civicrm_group', 15, 1 ) , ( 3, 4, 'civicrm_group', 2, 1 ) , ( 4, 2, 'civicrm_group', 2, 1 ) ;
MySQL said: Documentation
#1062 - Duplicate entry '1' for key 'PRIMARY'
Any help is appreciated. Kate