[0bdad5]: / inst / queries / allCohorts.xq

Download this file

8 lines (7 with data), 199 Bytes

1
2
3
4
5
6
7
;allCohorts
(fn [exclude]
(map :cohort
(query
{:select [[#sql/call [:distinct #sql/call [:ifnull :cohort "(unassigned)"]] :cohort]]
:from [:dataset]
:where [:not [:in :type exclude]]})))