select ‘condition_occurrence’ as table_name,condition_source_value as
source_value, COUNT_BIG(*) as cnt from @cdm_database_schema.
condition_occurrence where condition_concept_id = 0 group by
condition_source_value
It is counting records that didn’t map to a standard concept (so using
CONDITION_CONCEPT_ID, not CONDITION_SOURCE_CONCEPT_ID as you did in your
code, @ericaVoss).
Then I think we could have better text here then. I would suggest:
NOTIFICATION: Count of source values unmapped to standard concepts exceeds threshold:
If you agree, I’ll log an issue.
I still don’t match the count given by ACHILLES HEEL. I’m assuming I have to put the CNT > 1000 like is found associated to RULE 34.
SELECT *
FROM (
select 'condition_occurrence' as table_name,
condition_source_value as source_value,
COUNT(*) as cnt
from condition_occurrence
where condition_concept_id = 0
group by condition_source_value
) z
WHERE CNT > 1000
I think I need someone to explain to me how the RULEIDs are getting implemented now, it looks a bit different than before.
Yes, good point. I’m not sure why the CNT>1000 is in there, @Vojtech_Huser
will have to provide the insight there. I suspect the idea is that we are
more interesting in commonly-occurring unmapped codes rather than random
one-offs.