Show Categories Without Products
#1 · 1 of 10Free sampleQuestion
Show Categories Without Products
Find all
categories that do not have any products. Return category_id and category_name. Use a LEFT JOIN from categories to products and filter for categories whose product_id is NULL.Tables10 tables · 36 columns
Tables
10 tables · 36 columnscustomers7 cols
- customer_idINTEGER
- first_nameTEXT
- last_nameTEXT
- emailTEXT
- cityTEXT
- join_dateTEXT
- phoneTEXT
orders4 cols
- order_idINTEGER
- customer_idINTEGER
- shipping_idINTEGER
- order_dateTEXT
categories2 cols
- category_idINTEGER
- category_nameTEXT
products3 cols
- product_idINTEGER
- product_nameTEXT
- category_idINTEGER
departments2 cols
- department_idINTEGER
- department_nameTEXT
employees5 cols
- employee_idINTEGER
- first_nameTEXT
- last_nameTEXT
- hire_dateTEXT
- department_idINTEGER
cities3 cols
- city_idINTEGER
- city_nameTEXT
- stateTEXT
suppliers3 cols
- supplier_idINTEGER
- supplier_nameTEXT
- city_idINTEGER
shipping_addresses3 cols
- shipping_idINTEGER
- addressTEXT
- cityTEXT
inventory_movements4 cols
- inventory_idINTEGER
- product_idINTEGER
- change_quantityINTEGER
- reasonTEXT
Loading the practice editor and dataset…
Sign up to unlock
The reference answer is one click away.
Free account unlocks the reference answer, the explanation, and the GPT tutor on every exercise in the library.
- Reference answer + explanation revealed after each attempt
- GPT tutor for every problem
- Progress saved on the platform
- 1,598 graded exercises
- Free forever — no credit card
