Query Module for FHIR-based Study Eligibility Screening
Query module - recruIT
Summary
The query module runs SQL criteria against clinical data stored as FHIR resources to periodically identify candidates for research studies. It writes a screening list of potentially eligible patients back to the FHIR server.
Details
This module executes study eligibility criteria using SQL against clinical data. It supports multiple data sources, including Trino querying FHIR resources stored as Delta Lake tables, embedded DuckDB reading NDJSON files, or direct SQL on an FHIR server. Study criteria are defined within the Group characteristic of a ResearchStudy, with the actual SQL stored in a Library resource. The results are written back to the FHIR server as ResearchSubject and Observation resources, recording the eligibility status (is_met, is_indeterminate) for each candidate. Developers must consider data modeling aspects, such as ensuring consistent patient IDs, handling missing data (NULL), and managing the negation of exclusion criteria in their SQL queries. The module also includes a 'Dry Run' feature, allowing users to simulate the execution and count the potential list size without writing data to the production FHIR server.
Original content copyright by respective publishers