Write a SQL query to aggregate user interaction data over a specific time window.
Use the users and interaction_events tables. Analyze events from 2025-01-01 00:00:00 inclusive through 2025-02-01 00:00:00 exclusive. Include every user, including users with no interactions in the time window. Treat missing durations as zero.
user_id, user_name, interaction_count, total_duration_seconds, and last_interaction_at.| Column | Type | Description |
|---|---|---|
| user_idPK | INT | Unique user identifier |
| user_name | VARCHAR(100) | Display name of the user |
| Column | Type | Description |
|---|---|---|
| interaction_idPK | INT | Unique interaction event identifier |
| user_id | INT | User identifier associated with the event |
| interacted_at | TIMESTAMP | Timestamp when the interaction occurred |
| event_type | VARCHAR(50) | Type of user interaction |
| duration_seconds | INT | Duration of the interaction in seconds |