Your question is SQL: Highest Votes State. Start with the requirements and the two tables on the right.
Run and submit as often as you like. When you're ready, talk me through your approach or go straight to the code.
Fractal's election analytics team is reviewing state-level participation totals. Write a PostgreSQL query to identify the state or states that recorded the highest number of votes.
states to state_votes using state_id.state_name and total_votes.| Column | Type | Description |
|---|---|---|
| state_idPK | INT | Unique state identifier |
| state_name | VARCHAR(100) | State name |
| Column | Type | Description |
|---|---|---|
| vote_idPK | INT | Unique vote-count record identifier |
| state_id | INT | State associated with the vote-count record |
| vote_count | INT | Number of votes represented by the record |