Skip to content

All-Access: every lesson, no ads. $8.25€8.25US$8.25$4.08US$4.08$2.41US$2.41₹224.91MX$74.91 a month, billed yearly. Free to start. Cancel any time

See plans
All-Access, no ads: every lesson, course and template. $8.25€8.25US$8.25$4.08US$4.08$2.41US$2.41₹224.91MX$74.91 a month. + GST at checkoutSee the plans →

In SQL, you can use a JOIN to combine different tables. You join them by a common column, like the customer_id in both tables below. <br><br> We can match the customer_id in the orders with the customer_id in the customers table to combine the tables and get a result that you couldn't get from either table alone. Try:

Table customers

customer_idcustomer_namecountry
1AliceUSA
2BobCanada
3CarlosSpain
4DianaUK

Table orders

order_idcustomer_idorder_total
101145.99
102189.50
103222.00
1045100.00

JOIN - Combining Tables - SQL Practice Online

Practise JOIN - Combining Tables with 10 interactive SQL exercises. You type real queries into your browser and get instant feedback on every answer - no database setup and no install. It is a fast, hands-on way to learn SQL online and build query skills you can use at work.