IoT sample database — MongoDB, embedded (113,638 rows)

Tables that belong to another are folded into it as arrays, so the documents read the way the application uses them. The rest are collections of their own, joined by key as in the flat version.

Load it:
  sh import.sh                    (into mongodb://localhost:27017)
  sh import.sh "<connection string>"

Or one collection at a time: mongoimport --db iot --collection <name> --file <name>.ndjson

Collections:
  actuators — 50 documents, each with its actuator_commands
  alarm_rules — 200 documents
  alarms — 500 documents
  api_keys — 60 documents
  audit_logs — 1,000 documents
  billing_plans — 4 documents
  device_groups — 60 documents, each with its device_group_members
  device_metrics — 5,000 documents
  device_types — 10 documents
  devices — 100 documents, each with its device_configurations, its device_geofences
  error_logs — 1,000 documents
  firmware_deployments — 400 documents
  firmware_releases — 40 documents
  gateways — 80 documents, each with its gateway_devices
  geofences — 40 documents
  locations — 10 documents
  maintenance_logs — 200 documents
  network_connections — 1,000 documents
  networks — 60 documents
  notifications — 1,000 documents
  organizations — 20 documents
  roles — 4 documents
  sensors — 200 documents
  subscriptions — 20 documents
  support_tickets — 100 documents
  telemetry_data — 100,000 documents
  ticket_replies — 300 documents
  users — 300 documents, each with its user_roles

Folded in (no collection of their own):
  actuator_commands — 1,000 rows, as the "actuator_commands" array on actuators (its actuator_id is the parent's _id)
  device_configurations — 300 rows, as the "device_configurations" array on devices (its device_id is the parent's _id)
  device_geofences — 100 rows, as the "device_geofences" array on devices (its device_id is the parent's _id)
  device_group_members — 80 rows, as the "device_group_members" array on device_groups (its device_group_id is the parent's _id)
  gateway_devices — 100 rows, as the "gateway_devices" array on gateways (its gateway_id is the parent's _id)
  user_roles — 300 rows, as the "user_roles" array on users (its user_id is the parent's _id)

Types: numeric columns are Decimal128, so totals stay exact; dates and timestamps are
Date values read as UTC (the data has no time zone); times and UUIDs are strings;
JSON columns are embedded objects.

Synthetic data, CC0-1.0, from databasesample.com. The same rows as the SQL and CSV files.
