Sample retail store sales data
Updated 3 November 2026. Fictional U.S. businesses and people, generated with a fixed seed.
What is in it
Each row is one department in one of ten fictional stores on one trading day, from 1 January 2024: receipts, items sold, gross sales, discounts, net sales, cost of goods, gross profit and margin. Weekends and the holiday season are busier, and margins differ by department, so a store-by-department report has something to show.
More practice tables like this one: all 22 newer sample datasets.
First rows
point at a column to light it up
| record_idtext | sale_datedate | store_idtext | citytext | statetext | regiontext | departmenttext | transactionsnumber | units_soldnumber | gross_salesnumber | discountsnumber | net_salesnumber | cost_of_goodsnumber | gross_profitnumber | gross_margin_pctnumber |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| RS500001 | 2024-01-01 | ST01 | New York | NY | Northeast | Grocery | 545 | 1306 | 8029.6 | 517.64 | 7511.96 | 5730.42 | 1781.54 | 23.7 |
| RS500002 | 2024-01-01 | ST02 | Chicago | IL | Midwest | Grocery | 313 | 790 | 5219.03 | 170.38 | 5048.65 | 4104.48 | 944.17 | 18.7 |
| RS500003 | 2024-01-01 | ST03 | Houston | TX | South | Grocery | 297 | 750 | 4780.28 | 139.34 | 4640.94 | 3537.91 | 1103.03 | 23.8 |
| RS500004 | 2024-01-01 | ST04 | Dallas | TX | South | Grocery | 367 | 899 | 6051.97 | 151.49 | 5900.48 | 4607.85 | 1292.63 | 21.9 |
| RS500005 | 2024-01-01 | ST05 | Atlanta | GA | South | Grocery | 453 | 1264 | 7470.66 | 166.03 | 7304.63 | 5472.28 | 1832.35 | 25.1 |
| RS500006 | 2024-01-01 | ST06 | Miami | FL | South | Grocery | 528 | 1472 | 9751.5 | 361.55 | 9389.95 | 7252.38 | 2137.57 | 22.8 |
| RS500007 | 2024-01-01 | ST07 | Los Angeles | CA | West | Grocery | 550 | 1425 | 8959.09 | 203.51 | 8755.58 | 6550.28 | 2205.3 | 25.2 |
| RS500008 | 2024-01-01 | ST08 | Seattle | WA | West | Grocery | 451 | 1061 | 7010.47 | 323.84 | 6686.63 | 5050.35 | 1636.28 | 24.5 |
| RS500009 | 2024-01-01 | ST09 | Denver | CO | West | Grocery | 427 | 1164 | 7327.37 | 230.81 | 7096.56 | 5458.73 | 1637.83 | 23.1 |
| RS500010 | 2024-01-01 | ST10 | Boston | MA | Northeast | Grocery | 431 | 1044 | 6947.03 | 248.08 | 6698.95 | 5266.67 | 1432.28 | 21.4 |
Net sales by store
USD, 1,000-row file
Show as a table
| store_id | value |
|---|---|
| ST06 | $985,936 |
| ST01 | $901,489 |
| ST07 | $836,474 |
| ST05 | $821,096 |
| ST08 | $797,684 |
| ST09 | $764,291 |
| ST10 | $703,347 |
| ST04 | $561,313 |
| ST02 | $470,751 |
| ST03 | $465,227 |
Data dictionary
| Column | Type | Meaning |
|---|---|---|
| record_id | text | Row number |
| sale_date | date | Trading day (one row per store, department and day, from 2024-01-01) |
| store_id | text | ST01 to ST10 |
| city | text | Store city |
| state | text | Store state |
| region | text | Census region |
| department | text | Grocery, Apparel, Home, Electronics or Beauty |
| transactions | integer | Number of sales receipts |
| units_sold | integer | Items sold |
| gross_sales | decimal | Sales before discounts (USD) |
| discounts | decimal | Markdowns and coupons (USD) |
| net_sales | decimal | gross_sales - discounts (USD) |
| cost_of_goods | decimal | What the items cost the retailer (USD) |
| gross_profit | decimal | net_sales - cost_of_goods (USD) |
| gross_margin_pct | decimal | 100 x gross_profit / net_sales, one decimal |
Practice questions
answers checked in SQL and in Python
Net sales by store?
ST06 $985,935.85; ST01 $901,489.32; ST07 $836,473.66; ST05 $821,095.58; ST08 $797,684.24; ST09 $764,290.80; ST10 $703,347.26; ST04 $561,312.65; ST02 $470,750.51; ST03 $465,226.59
Excel
=SUMIFS(L:L,C:C,"ST01")SQL
SELECT store_id, ROUND(SUM(net_sales),2) AS n FROM retail_store_sales GROUP BY store_id ORDER BY n DESC, store_idFile: retail-store-sales-1000
Gross margin % by department (total gross profit / total net sales)?
Apparel 46.0%; Beauty 44.1%; Home 38.1%; Grocery 23.9%; Electronics 22.0%
Excel
=SUMIFS(N:N,G:G,"Grocery")/SUMIFS(L:L,G:G,"Grocery")SQL
SELECT department, ROUND(100.0*SUM(gross_profit)/SUM(net_sales),1) AS m FROM retail_store_sales GROUP BY department ORDER BY m DESC, departmentFile: retail-store-sales-1000
Total discounts given in the Electronics department?
$192,082.90
Excel
=SUMIFS(K:K,G:G,"Electronics")SQL
SELECT ROUND(SUM(discounts),2) FROM retail_store_sales WHERE department = 'Electronics'File: retail-store-sales-1000