From a call-records table (caller, receiver), pull the list of users of a given type for a promotion, accounting for users appearing as either caller or receiver.
Asked in the technical screen stage. The question reused the first question's data and required combining caller and receiver appearances.
users who appears in either role in call_records and has user_type = 'creator'.user_id and user_name, ordered by user_id ascending.| Column | Type | Description |
|---|---|---|
| user_idPK | INT | Unique user identifier |
| user_name | VARCHAR(100) | Display name of the user |
| user_type | VARCHAR(30) | Classification used to target promotions |
| Column | Type | Description |
|---|---|---|
| call_idPK | INT | Unique call-record identifier |
| caller_id | INT | User who initiated the call |
| receiver_id | INT | User who received the call |