BrightCart wants to measure how effectively each acquisition channel turns signups into paying customers. Write a SQL query to calculate the conversion rate by acquisition channel.
users as the base table so channels with zero conversions are still included.subscriptions with status = 'active' or status = 'canceled'.acquisition_channeltotal_signupsconverted_usersconversion_rate_pct rounded to 2 decimal placesconversion_rate_pct descending, then acquisition_channel ascending.| Column | Type | Description |
|---|---|---|
| user_idPK | INT | Unique user identifier |
| acquisition_channel | VARCHAR(50) | Marketing channel that acquired the user |
| signup_date | DATE | Date the user signed up |
| country_code | VARCHAR(2) | User country code |
| Column | Type | Description |
|---|---|---|
| subscription_idPK | INT | Unique subscription record identifier |
| user_id | INT | User associated with the subscription |
| start_date | DATE | Subscription start date |
| status | VARCHAR(20) | Subscription lifecycle status |
| monthly_amount | NUMERIC(10,2) | Monthly subscription amount |