sub-job
SunLife · Load-Visits
Runs visit and eligibility processing Update [date]: Disabling the CheckVisitGFEComplianceBatch task because it is blowing up processing (ran for >24 hours before being killed) and because no one knows what it does. Can re-enable if it is determined to be necessary and we can invest time to figure out how to properly fix it. -CW
task tree
What the sub-job runs
Tasks in order, each with what it does — typed stepsfrom the MDClarity task docs (click to open the reference), sub-jobsyou can expand inline (▶) to reveal their own tasks, and SQL steps summarized by Gemini (✨). Every step shows the tables it writes/reads and which earlier step it feeds from(sqlglot lineage).
sub-job
Load-Visits
9 tasks · SunLife
sub-job / Flow action SQL / native step▶ expand a sub-job inline · ↗ open it as its own page · a typed step opens its doc
- LoadVisitBatchLoadVisitBatchLoad scheduled visits and associated charges into the processing pipeline using custom SQL queries for pricing estimation and quote generation.writes
QuoteBatchVisitBatch· readsPatientTransformUpdatedVisitChargeTransformVisitTransformVisitInsuranceVisitVisitDeltavisitdelta↳ feeds from Sync QuoteBatch,VisitBatch,CustomPropertyMapBatchcustom visit querycustom charge queryauto service type queryauto coverage queryadd zero charge - CalculateVisitsflowCompute the good-faith estimate (CalculateVisits).· reads
DimensionMemberVisitBatch↳ feeds from LoadVisitBatchcustom querycalculate chargesbatch mode ▶Load-Custom-Propertiessub-job · 11↗Load custom properties from Load-Visits
- UpdateVisitCustomPropertyFromQueryUpdateVisitCustomPropertyFromQuerydisabled· reads
InsuranceSearch_ResultTransformVisitInsuranceCoverageStatusVisitBatchcustom visit update custom property queryDISABLED - Custom Properties: OtherActiveCoverageUpdateVisitCustomPropertyFromQuerydisabled· reads
TransformVisitInsuranceCoverageStatusVisitBatchcustom visit update custom property queryDISABLED - Custom Properties: OtherInactiveCoverageUpdateVisitCustomPropertyFromQuerydisabled· reads
TransformVisitInsuranceCoverageStatusVisitBatchcustom visit update custom property queryDISABLED - Custom Properties: Update MostRecentBatch to clear the previous recordsUpdateVisitCustomPropertyFromQuerydisabled· reads
CustomPropertyMapVisitcustom visit update custom property queryDISABLED - Custom Properties: MostRecentBatchUpdateVisitCustomPropertyFromQuerydisabledauto visit update custom property queryDISABLED
- Custom Properties: OAS ReasonUpdateCustomPropertyFromQuerydisabled· reads
CustomPropertyMapsourceappointmentchaintransformcustompropertiesvisitbatchvisitdeltaentity=Visitcustom property key=OASReasonauto querybatch modeDISABLED - Custom Properties: Has BundleUpdateCustomPropertyFromQuerydisabled· reads
CustomPropertyMapTransformVisitChargeVisitBatchvisitdeltaentity=Visitcustom property key=HasBundleauto querybatch modeDISABLED - Custom Properties: GFE ReasonUpdateCustomPropertyFromQuerydisabled· reads
CustomPropertyMaptransformcustompropertiesvisitbatchvisitdeltaentity=Visitcustom property key=GFEReasoncustom querybatch modeDISABLED - Custom Properties: Set LetterPrinted to NoUpdateCustomPropertyFromQuerydisabled· reads
CustomPropertyMapVisitBatchentity=Visitcustom property key=LetterPrintedcustom querybatch modeDISABLED - UpdateCustomPropertyFromQuery (GFEDueDate)UpdateCustomPropertyFromQuerydisabled· reads
SourceEncounterTransformVisitVisitBatchentity=Visitcustom property key=GFEDueDatecustom querybatch modeDISABLED - Custom Properties: HasOBPackageUpdateCustomPropertyFromQuery· reads
TransformVisitInsuranceVisitBatchentity=Visitcustom property key=HasOBPackagecustom querybatch mode
- LogVisitChangeEventsBatchLogVisitChangeEventsBatchCompare batch visits against production records to detect and log specific property changes for auditing and compliance tracking.
- Audits Good Faith Estimate compliance for batch visits and identifies records requiring resends based on federal timing regulations.DISABLED
- Generates and sends patient cost estimate letters for visits in the batch table based on configured qualification and communication rules.DISABLED
- Synchronizes processed data from batch staging tables to production tables, updating visits, quotes, and custom property mappings.writes
CustomPropertyMapQuoteVisitVisitChangeEvent· readsCustomPropertyMapBatchQuoteBatchVisitBatchVisitChangeEventBatch↳ feeds from LoadVisitBatchsync quotesync visitsync custom property mapsync removed custom property mapssync visit change event ▶Load-Visit-Factsub-job · 2↗
- Create Visit Factsql
load_visit_fact__create_visit_fact.sql✨ Builds the visit fact table structure to store comprehensive encounter metrics, insurance status, and payment details. - Load Visit Factsql
load_visit_fact__load_visit_fact.sql✨ Loads visit fact data by identifying and refreshing records with recent activity in payments, eligibility, or letters.writesVisitFactVisitFactDelta· readsActivityLogCustomPropertyMapEligibilityStatusMapEligibilityTxnPatientLetterPaymentTxnVisitVisitFactDelta
- UpdateDashboardTablesUpdateDashboardTablesRegenerates optimized aggregate tables for all dashboard reports and updates their definitions to reflect the latest source data.