Work in Progress: This page is under development. Use the feedback button on the bottom right to help us improve it.

Sample Data

All SQL examples in this documentation use the following datasets. Bookmark this page for reference.


orders

The main transaction table tracking customer purchases.

order_idcustomer_idamountstatusregiontimestamp
ord_1c1150.00completedus-east2024-01-15 10:00:15
ord_2c275.50completedus-west2024-01-15 10:00:35
ord_3c1200.00pendingus-east2024-01-15 10:01:10
ord_4c350.00cancelledeu-west2024-01-15 10:01:45
ord_5c2300.00completedus-west2024-01-15 10:02:20
ord_6c4125.00completedus-east2024-01-15 10:02:55
ord_7c189.99completedus-east2024-01-15 10:03:30
ord_8c5450.00pendingeu-west2024-01-15 10:04:05

Schema:

CREATE TABLE orders (
  order_id VARCHAR,
  customer_id VARCHAR,
  amount DECIMAL(10,2),
  status VARCHAR,
  region VARCHAR,
  timestamp TIMESTAMP
)

events

User activity and clickstream events.

event_iduser_idevent_typepagesession_idtimestamp
e1u1page_view/homesess_12024-01-15 10:00:05
e2u1click/productssess_12024-01-15 10:00:12
e3u2page_view/homesess_22024-01-15 10:00:18
e4u1add_to_cart/products/1sess_12024-01-15 10:00:25
e5u2click/aboutsess_22024-01-15 10:00:32
e6u1purchase/checkoutsess_12024-01-15 10:00:45
e7u3page_view/homesess_32024-01-15 10:01:00
e8u2page_view/productssess_22024-01-15 10:01:15

Schema:

CREATE TABLE events (
  event_id VARCHAR,
  user_id VARCHAR,
  event_type VARCHAR,
  page VARCHAR,
  session_id VARCHAR,
  timestamp TIMESTAMP
)

logs

Application log messages for text processing examples.

log_idlevelmessageservicetimestamp
l1INFOUser login successful user_id=u1 ip=192.168.1.1auth2024-01-15 10:00:05
l2ERRORPayment failed order_id=ord_3 error=insufficient_fundspayment2024-01-15 10:01:12
l3WARNHigh latency detected endpoint=/api/orders latency_ms=2500api2024-01-15 10:01:45
l4INFOOrder created order_id=ord_5 customer_id=c2orders2024-01-15 10:02:20
l5ERRORConnection timeout service=inventory retry=3inventory2024-01-15 10:02:55
l6INFOCache hit rate=0.85 keys=1250cache2024-01-15 10:03:30

Schema:

CREATE TABLE logs (
  log_id VARCHAR,
  level VARCHAR,
  message VARCHAR,
  service VARCHAR,
  timestamp TIMESTAMP
)

metrics

Numeric time-series data for math and statistical examples.

metric_idnamevaluetagstimestamp
m1cpu_usage45.5host=server12024-01-15 10:00:00
m2cpu_usage62.3host=server12024-01-15 10:01:00
m3cpu_usage38.7host=server22024-01-15 10:00:00
m4memory_mb2048host=server12024-01-15 10:00:00
m5memory_mb2156host=server12024-01-15 10:01:00
m6cpu_usage71.2host=server12024-01-15 10:02:00
m7cpu_usage55.8host=server22024-01-15 10:01:00
m8requests1250endpoint=/api2024-01-15 10:00:00

Schema:

CREATE TABLE metrics (
  metric_id VARCHAR,
  name VARCHAR,
  value DOUBLE,
  tags VARCHAR,
  timestamp TIMESTAMP
)

Use these datasets as you follow along with the SQL examples throughout the documentation.