Export filter keeps all instances of a condition type when an active instance exists
Closed this issue · 0 comments
dehall commented
What happened?
The export filter is incorrectly keeping historical instances of Condition when there is an active instance of the same type.
Relevant code:
Consider for example a patient that has multiple instances of Viral Sinusitis, or in the example I found, "Medication Review Due". If they currently have an active instance of the condition, this predicate will return true
for every instance of that condition across their record, which isn't what we want. I believe we only need to look at start & stop date but this requires more review.
Sample patient attached: Ciera654_Boyle917_45aa9ffe-bb1e-c459-9f42-1944832cb8d1.json
Environment
- OS: macOS 13.6
- Java: openjdk version "17.0.8" 2023-07-18
- Run command: `./run_synthea -s 1 -cs 1 -r 20231024 -ps -4964420948893066024`
Relevant log output
No response