From c594c3097d067735b924009d66fc47df0dce42eb Mon Sep 17 00:00:00 2001 From: Erich Eckner Date: Mon, 29 Apr 2019 13:23:08 +0200 Subject: misc/database-layout.dump: `calculate_maximal_moveable_set` operates on a per-arch basis, now --- misc/database-layout.dump | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'misc') diff --git a/misc/database-layout.dump b/misc/database-layout.dump index c88ea10..58cc4b4 100644 --- a/misc/database-layout.dump +++ b/misc/database-layout.dump @@ -61,7 +61,7 @@ SELECT `architectures`.`name`,`bl`.`pkgbase` DROP TEMPORARY TABLE `bl`; DROP TEMPORARY TABLE `bl_copy`; END utf8mb4 utf8mb4_unicode_ci utf8mb4_unicode_ci -calculate_maximal_moveable_set STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION CREATE DEFINER=`root`@`localhost` PROCEDURE `calculate_maximal_moveable_set`(IN `from_stability` MEDIUMINT) +calculate_maximal_moveable_set STRICT_TRANS_TABLES,ERROR_FOR_DIVISION_BY_ZERO,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION CREATE DEFINER=`root`@`localhost` PROCEDURE `calculate_maximal_moveable_set`(IN `arch_id` MEDIUMINT,IN `from_stability` MEDIUMINT) BEGIN DECLARE row_count_saved INT DEFAULT 0; DROP TEMPORARY TABLE IF EXISTS `moveable_bpir`; @@ -98,7 +98,7 @@ INSERT IGNORE INTO `package_blobs` (`ps_a`,`ps_b`) ON `b_bp`.`id`=`b_bpir`.`package` JOIN `repositories` AS `b_r` ON `b_bpir`.`repository`=`b_r`.`id` - WHERE `a_r`.`stability` = `from_stability` AND `b_r`.`stability` = `from_stability`; + WHERE `a_r`.`stability` = `from_stability` AND `a_r`.`architecture` = `arch_id` AND `b_r`.`stability` = `from_stability` AND `b_r`.`architecture` = `arch_id`; INSERT IGNORE INTO `moveable_bpir` (`id`,`to_repository`) SELECT `binary_packages_in_repositories`.`id`,`repository_moves`.`to_repository` FROM `binary_packages_in_repositories` @@ -116,7 +116,7 @@ INSERT IGNORE INTO `moveable_bpir` (`id`,`to_repository`) ON `package_sources`.`upstream_package_repository`=`upstream_repositories`.`id` JOIN `repository_moves` ON `upstream_repositories`.`id`=`repository_moves`.`upstream_package_repository` AND `repository_moves`.`from_repository`=`binary_packages_in_repositories`.`repository` - WHERE `repository_stabilities`.`id`=`from_stability` AND (`repository_stabilities`.`name`="staging" OR `binary_packages`.`is_tested`) AND NOT `binary_packages`.`has_issues`; + WHERE `repository_stabilities`.`id`=`from_stability` AND `repositories`.`architecture`=`arch_id` AND (`repository_stabilities`.`name`="staging" OR `binary_packages`.`is_tested`) AND NOT `binary_packages`.`has_issues`; INSERT IGNORE INTO `package_blobs` (`ps_a`,`ps_b`) SELECT `package_sources`.`id`,`package_sources`.`id` FROM `package_sources` @@ -128,7 +128,7 @@ INSERT IGNORE INTO `package_blobs` (`ps_a`,`ps_b`) ON `binary_packages`.`id`=`binary_packages_in_repositories`.`package` JOIN `repositories` ON `binary_packages_in_repositories`.`repository`=`repositories`.`id` - WHERE `repositories`.`stability`=`from_stability`; + WHERE `repositories`.`stability`=`from_stability` AND `repositories`.`architecture`=`arch_id`; INSERT IGNORE INTO `replaced_bpir` (`id`,`replaced_by`) SELECT `r_bpir`.`id`,`m_bpir`.`id` FROM `moveable_bpir` -- cgit v1.2.3-70-g09d2