Codington
0 of 8 problems solved • 0%

Exercise prompt

Trace Two Different IDs

Deployment 20 and service 20 both exist. To identify what was deployed, follow the service_id on the deployment row. Use a column alias to give each ID a clear heading.

Example

SELECT s.id AS registry_id, s.name FROM services AS s WHERE s.id = 10;

Your task

Look up deployment 20 using INNER JOIN. Return the deployment ID as run_id, the matched service’s primary key as service_id, and its name, in that order.

Opening the database…