DataBolt

SQL LEARNING PLATFORM

2

INTRO 2

Your Sample Database

And why is it one of the most valuable skills you can learn in tech?

8

Learning Blocks

SQL

Interactive Queries

In This Chapter

Concepts you'll master

1

The five tables we will query throughout every chapter

2

How tables relate to each other via primary and foreign keys

3

How to read and interpret a database schema

employees

emp_idnamedepartmentsalarymanager_idhire_date
1ArjunIT850002020-06-15
2PriyaIT7200012021-03-10
3RahulSales5500052022-01-20
4SnehaHR6000052021-07-08
5VikramSales900002019-11-01
6DivyaIT6800012023-02-14
7KiranHR5800042022-08-30
8MeeraSales6200052023-05-12

products

product_idnamecategorypricestock
1iPhone 15Electronics7999950
2SQL BookBooks499200
3HeadphonesElectronics299975
4NotebookStationery99500
5LaptopElectronics6500020
6Pen SetStationery1490
7MouseElectronics59925

customers

customer_idnamecitycountry
1AnanyaHyderabadIndia
2RohanBangaloreIndia
3SamMumbaiIndia
4LisaLondonUK
5RaviDelhiIndia

orders

order_idcustomer_idorder_datetotalstatus
112024-01-1579999completed
222024-01-203498completed
312024-02-1065000completed
432024-02-14499pending
522024-03-01248completed
652024-03-152999shipped
712024-04-05149completed

orders_items

item_idorder_idproduct_idqtyunit_price
111179999
22312999
3221499
435165000
5421499
654299
756150
86312999

💡 Note: Lisa (customer_id 4) has no orders. Pen Set (product_id 6) has stock = 0. These "edge cases" are intentional — they are used to illustrate LEFT JOIN and NULL behaviour in later chapters.