diff options
author | Dan Goodliffe <dan@randomdan.homeip.net> | 2016-10-04 00:26:52 +0100 |
---|---|---|
committer | Dan Goodliffe <dan@randomdan.homeip.net> | 2016-10-04 00:26:52 +0100 |
commit | d792e0bf6c8cd37e2ab0ab9e203c77dde17d44cb (patch) | |
tree | 2d092cddf356a101bd348b55ca1ebf783e3795af | |
parent | Add slicer collection element metadata (diff) | |
download | gentoobrowse-api-d792e0bf6c8cd37e2ab0ab9e203c77dde17d44cb.tar.bz2 gentoobrowse-api-d792e0bf6c8cd37e2ab0ab9e203c77dde17d44cb.tar.xz gentoobrowse-api-d792e0bf6c8cd37e2ab0ab9e203c77dde17d44cb.zip |
Filter out partial blocks and set blocks flag only on full ones in all kinds dependency
3 files changed, 6 insertions, 4 deletions
diff --git a/gentoobrowse-api/service/sql/portage/getPackageDependencies.sql b/gentoobrowse-api/service/sql/portage/getPackageDependencies.sql index 5a6b6c9..4e94348 100644 --- a/gentoobrowse-api/service/sql/portage/getPackageDependencies.sql +++ b/gentoobrowse-api/service/sql/portage/getPackageDependencies.sql @@ -1,6 +1,7 @@ -SELECT p.packageid, p.categoryid, p.name, p.description, p.summary, p.firstseen, p.maintainer, p.maintainername, p.herd, array_agg(e.ebuildid order by e.ebuildid) ebuildids, position('!' in d.op) > 0 block +SELECT p.packageid, p.categoryid, p.name, p.description, p.summary, p.firstseen, p.maintainer, p.maintainername, p.herd, array_agg(e.ebuildid order by e.ebuildid) ebuildids, '!' = d.op block FROM gentoobrowse.packages p, gentoobrowse.ebuilds e, gentoobrowse.ebuild_deps d WHERE e.packageid = ? AND e.ebuildid = d.ebuildid AND p.packageid = d.packageid +AND d.op NOT LIKE '!_%' GROUP BY p.packageid, block diff --git a/gentoobrowse-api/service/sql/portage/getPackageRuntimeDependencies.sql b/gentoobrowse-api/service/sql/portage/getPackageRuntimeDependencies.sql index e74d0d0..79ace98 100644 --- a/gentoobrowse-api/service/sql/portage/getPackageRuntimeDependencies.sql +++ b/gentoobrowse-api/service/sql/portage/getPackageRuntimeDependencies.sql @@ -1,7 +1,7 @@ -SELECT p.packageid, p.categoryid, p.name, p.description, p.summary, p.firstseen, p.maintainer, p.maintainername, p.herd, array_agg(e.ebuildid order by e.ebuildid) ebuildids, position('!' in d.op) > 0 block +SELECT p.packageid, p.categoryid, p.name, p.description, p.summary, p.firstseen, p.maintainer, p.maintainername, p.herd, array_agg(e.ebuildid order by e.ebuildid) ebuildids, '!' = d.op block FROM gentoobrowse.packages p, gentoobrowse.ebuilds e, gentoobrowse.ebuild_rdeps d WHERE e.packageid = ? AND e.ebuildid = d.ebuildid AND p.packageid = d.packageid +AND d.op NOT LIKE '!_%' GROUP BY p.packageid, block - diff --git a/gentoobrowse-api/service/sql/portage/getPackagesDepending.sql b/gentoobrowse-api/service/sql/portage/getPackagesDepending.sql index c86d1f9..626a857 100644 --- a/gentoobrowse-api/service/sql/portage/getPackagesDepending.sql +++ b/gentoobrowse-api/service/sql/portage/getPackagesDepending.sql @@ -1,4 +1,4 @@ -SELECT p.packageid, p.categoryid, p.name, p.description, p.summary, p.firstseen, p.maintainer, p.maintainername, p.herd, array_agg(e.ebuildid order by e.ebuildid) ebuildids, position('!' in d.op) > 0 block +SELECT p.packageid, p.categoryid, p.name, p.description, p.summary, p.firstseen, p.maintainer, p.maintainername, p.herd, array_agg(e.ebuildid order by e.ebuildid) ebuildids, '!' = d.op block FROM gentoobrowse.packages p, gentoobrowse.ebuilds e, ( SELECT d.ebuildid, d.packageid, d.op FROM gentoobrowse.ebuild_rdeps d @@ -8,4 +8,5 @@ FROM gentoobrowse.packages p, gentoobrowse.ebuilds e, ( WHERE d.packageid = ? AND e.ebuildid = d.ebuildid AND p.packageid = e.packageid +AND d.op NOT LIKE '!_%' GROUP BY p.packageid, block |