Hospital Revenue Cycle Management Path · Mission 3 of 25Easy

Charges per CPT code

First aggregation on fact_charges joined to dim_cpt. Per-CPT charge volume is the headline shape behind every charge capture audit, every coding-pattern review, and every revenue rollup; every Medium / Hard / Expert mission downstream extends this skeleton.

The Brief

Maria SantosBilling Analystslack-dm

Standing charge capture audit — I need the headline number for tomorrow's Wednesday review. Across the full 24-month window in fact_charges, give me the total charge count per CPT. Use cpt_code + description from dim_cpt so the slide reads cleanly. Three columns: cpt_code, description, charge_count. Sort by charge_count descending — high-volume E&M codes (99213, 99214) should lead. Don't filter on date or anything else; we want the full window.

You'll practice

INNER JOINGROUP BYCOUNT(*)

Tables & columns available

fact_chargesfact7 columns
ColumnTypeKey
charge_idINTPK
patient_idINTFK → dim_patient
provider_idINTFK → dim_provider
cpt_codeTEXTFK → dim_cpt
service_dateTEXT
billed_amountREAL
posted_amountREAL
dim_cptdim5 columns
ColumnTypeKey
cpt_codeTEXTPK
descriptionTEXT
service_lineTEXT
charge_amountREAL
rvuREAL

Hints (3)

Each hint you reveal reduces the XP you can earn. Try the query first.

Hint 1

Two-table aggregate. You'll need fact_charges (the volume) joined to dim_cpt (the readable description), grouped by the CPT key.

Hint 2

Group by cpt_code (and the description, since description is in the SELECT and not aggregated). COUNT(*) aliased as charge_count. Three-column output.

Hint 3

Sort descending on charge_count. Office-visit E&M codes carry the volume in any group practice; procedure codes are higher dollars but lower volume.