Skip to content

Commit 864e972

Browse files
authored
Merge pull request #3898 from IntersectMBO/fix/network-metrics
Fix CommitteeThreshold query in network-metrics
2 parents de01ddc + f115d81 commit 864e972

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

govtool/backend/sql/get-network-metrics.sql

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -186,9 +186,9 @@ CommitteeThreshold AS (
186186
SELECT
187187
c.*
188188
FROM committee c
189-
LEFT JOIN LatestGovAction lga ON c.gov_action_proposal_id = lga.id
190-
WHERE (c.gov_action_proposal_id IS NOT NULL AND lga.id IS NOT NULL)
191-
OR (c.gov_action_proposal_id IS NULL)
189+
where
190+
( c.gov_action_proposal_id = (Select id from LatestGovAction))
191+
OR ( c.gov_action_proposal_id IS NULL)
192192
)
193193
SELECT
194194
UniqueDelegators.count AS unique_delegators,

0 commit comments

Comments
 (0)