Skip to content

Commit 45c82a2

Browse files
author
Luke Sikina
committed
[ALS-7382] - counts that are -1 should be shown as N/A
1 parent a2ad148 commit 45c82a2

File tree

1 file changed

+16
-4
lines changed

1 file changed

+16
-4
lines changed

src/main/java/edu/harvard/dbmi/avillach/dictionary/dashboard/DashboardRepository.java

+16-4
Original file line numberDiff line numberDiff line change
@@ -55,14 +55,26 @@ public List<Map<String, String>> getHackyBDCRows() {
5555
SELECT
5656
dataset.abbreviation AS abbreviation,
5757
dataset.full_name AS name,
58-
consent.variable_count AS clinvars,
59-
consent.participant_count AS participants,
60-
consent.sample_count AS samples,
58+
CASE
59+
WHEN consent.variable_count > -1 THEN consent.variable_count
60+
ELSE 'N/A'
61+
END
62+
AS clinvars,
63+
CASE
64+
WHEN consent.participant_count > -1 THEN consent.participant_count
65+
ELSE 'N/A'
66+
END
67+
AS participants,
68+
CASE
69+
WHEN consent.sample_count > -1 THEN consent.sample_count
70+
ELSE 'N/A'
71+
END
72+
AS samples,
6173
CASE
6274
WHEN consent.consent_code <> NULL THEN concat(study_accession_meta.value, '.', consent.consent_code)
6375
ELSE study_accession_meta.value
6476
END
65-
AS accession,
77+
AS accession,
6678
study_focus_meta.value AS study_focus,
6779
additional_info_meta.value AS additional_info_link
6880
FROM

0 commit comments

Comments
 (0)