provisioningTeamProfile

Problems with Pending Charges

Pending charges process can fail for many reasons. Some are that the CPT4 is invalid, some are its an expired SIM, some are a 0 quantity etc. Try the below scripts to search for these sitautions.

select * from service_item_mstr where cpt4_code_id not in (select cpt4_code_id from cpt4_code_mstr)
--does any of the sims have missing cpt4 codes?
select * from pending_charge pc
left join patient_procedure pp on pc.uniq_id = pp.uniq_id
left join service_item_mstr sim on sim.service_item_lib_id = pp.service_item_lib_id and sim.service_item_id = pp.service_item_id and sim.exp_date = (select top 1 exp_date from service_item_mstr sim2 where sim.service_item_lib_id = sim2.service_item_lib_id and sim.service_item_id = sim2.service_item_id order by exp_date desc)
where sim.exp_date < getdate()
--do any of the pending charges have expired sims?
select * from pending_charge pc
left join patient_procedure pp on pc.uniq_id = pp.uniq_id
where pp.qty <1 or pp.qty = '' or pp.qty is null