Back Practice ↓

Related Practice & In-Depth Concepts

↑ Read lesson

Task:Write a query to create an intersection table for a many-to-many relationship between `orders` and `products`. Name the table `order_items`. It should have an `order_id` (INTEGER) and a `product_id` (INTEGER). Define BOTH of them together as the PRIMARY KEY. (Do not create a separate 'id' column).
SQL Query Editor
No results returned. Press Run Query (or Cmd/Ctrl + Enter) to execute.