Your question is Employee Query With Unmatched IDs. 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.
Cimpress Technology needs an employee-project view for internal staffing. Write a PostgreSQL query that returns every employee from empdetails, including employees who have no matching project in projdetails.
LEFT JOIN from empdetails to projdetails using employee_id.NULL for project columns.firstname from empdetails, then firstname from projdetails, placing NULL values last in both sort levels.| Column | Type | Description |
|---|---|---|
| employee_idPK | INTEGER | Unique employee identifier |
| empname | VARCHAR(100) | Employee's full name |
| firstname | VARCHAR(50) | Employee's first name |
| Column | Type | Description |
|---|---|---|
| project_idPK | INTEGER | Unique project identifier |
| employee_id | INTEGER | Assigned employee identifier |
| project_name | VARCHAR(150) | Name of the project |
| firstname | VARCHAR(50) | Project contact or team first name |