SELECT DISTINCT department_id FROM employees;
retrieves the distinct department IDs from the "employees" table. Let's analyze the query in detail:SELECT DISTINCT
statement is used to retrieve unique or distinct values from a column in a table.DISTINCT
keyword ensures that only unique department IDs are returned.
|
Explore Courses for Software Development exam
|
|
Explore Courses for Software Development exam
|