[Blends-commit] [SCM] website branch, master, updated. 4fbe43e9d5a2574738858bf496d16392e60d6467

Andreas Tille tille at debian.org
Tue Sep 10 13:08:29 UTC 2013


The following commit has been merged in the master branch:
commit 4fbe43e9d5a2574738858bf496d16392e60d6467
Author: Andreas Tille <tille at debian.org>
Date:   Tue Sep 10 15:11:39 2013 +0200

    Use blends_dependencies_priorities lookup table to select only highest priority in case a source package has more than one binary package with different priorities in one task

diff --git a/misc/sql/bugs.sh b/misc/sql/bugs.sh
index 794ecf8..c87fb08 100755
--- a/misc/sql/bugs.sh
+++ b/misc/sql/bugs.sh
@@ -19,14 +19,17 @@ psql udd > $1_buggy_packages.out <<EOT
             GROUP BY s.source, b.dependency, b.component, s.homepage, s.vcs_browser, s.maintainer, s.version
         ) sources
         LEFT OUTER JOIN (
-          SELECT DISTINCT source, task AS tasks, dependency FROM (
-            SELECT DISTINCT p.source, b.task, dependency
+          SELECT source, task AS tasks, dependency FROM (
+            SELECT p.source, b.task, bdp.dependency, row_number() OVER (PARTITION BY p.source, b.task ORDER BY bdp.priority)
               FROM packages p
               JOIN releases r ON p.release = r.release
               JOIN blends_dependencies b ON b.package = p.package
               JOIN sources s ON p.source = s.source AND p.release = s.release
+              JOIN blends_dependencies_priorities bdp ON b.dependency = bdp.dependency
               WHERE b.blend = '$1'
+              GROUP BY p.source, b.task, bdp.dependency, bdp.priority
           ) tmp
+          WHERE row_number = 1
         ) tasks ON sources.source = tasks.source
         WHERE row_number = 1
         ORDER BY source;

-- 
Static and dynamic websites for Debian Pure Blends



More information about the Blends-commit mailing list