Write a SQL query to compare current month admissions with the previous month.
Use the latest non-null admission_date in the data to determine the current month. Count admission records for both months and calculate the absolute and percentage change.
current_month, current_admissions, previous_month, previous_admissions, change_count, and change_percentchange_percent rounded to two decimal places, or NULL when the previous count is zero| Column | Type | Description |
|---|---|---|
| admission_idPK | INT | Unique admission record identifier |
| patient_id | VARCHAR(20) | Patient identifier associated with the admission |
| admission_date | DATE | Date the admission was recorded |