CREATE TABLE `yeasts_to_yeasts` ( `id` int(11) unsigned NOT NULL AUTO_INCREMENT, `yeasts_id` int(11) unsigned NOT NULL, `replacements_id` int(11) unsigned NOT NULL, PRIMARY KEY (`id`), UNIQUE KEY `unique_yeast_replacement` (`yeasts_id`,`replacements_id`), KEY `index_yeast` (`yeasts_id`), KEY `index_replacement` (`replacements_id`), CONSTRAINT `yeasts_to_yeasts_ibfk_1` FOREIGN KEY (`yeasts_id`) REFERENCES `yeasts` (`id`) ON DELETE CASCADE, CONSTRAINT `yeasts_to_yeasts_ibfk_2` FOREIGN KEY (`replacements_id`) REFERENCES `yeasts` (`id`) ON DELETE CASCADE ) ENGINE=InnoDB AUTO_INCREMENT=364 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_520_ci