diff --git a/pkg/models/demographic/queries.go b/pkg/models/demographic/queries.go index df0a52d..8767417 100644 --- a/pkg/models/demographic/queries.go +++ b/pkg/models/demographic/queries.go @@ -123,6 +123,8 @@ func PeopleStatistics() People { COUNT(*) AS user_count FROM users + WHERE users.status = 'active' + AND users.certified IS TRUE GROUP BY CASE WHEN DATE_PART('year', AGE(birthdate)) BETWEEN 0 AND 25 THEN '18-25'