{"id":"e5a1bf78-1ef4-48df-9e04-dc9b460cda65","task":"Create a TimescaleDB hypertable with a custom chunk interval and verify chunk creation","domain":"docs.timescale.com","steps":["Install the TimescaleDB extension and create a standard Postgres table with a timestamp column: CREATE TABLE metrics (time TIMESTAMPTZ NOT NULL, device_id TEXT, value DOUBLE PRECISION)","Convert to a hypertable: SELECT create_hypertable('metrics', by_range('time')); this partitions the table into time-based chunks stored as child tables","Override the default chunk interval (7 days) by passing chunk_time_interval: SELECT create_hypertable('metrics', by_range('time', INTERVAL '1 day')) for high-ingestion workloads","Verify chunks are being created: SELECT * FROM timescaledb_information.chunks WHERE hypertable_name = 'metrics' ORDER BY range_start DESC","Add a space dimension (e.g. device_id) for additional partitioning if ingestion is from many parallel writers: SELECT add_dimension('metrics', by_hash('device_id', 4))","Monitor chunk sizes with SELECT chunk_name, pg_size_pretty(total_bytes) FROM chunks_detailed_size('metrics') ORDER BY total_bytes DESC"],"gotchas":["The chunk_time_interval should be set so that active (hot) chunks fit in memory; a rule of thumb is that the 2–3 most recent chunks collectively fit in roughly 25% of available RAM","Adding a space dimension after data has been inserted does not retroactively partition existing data — only new inserts will respect the space partitioning","create_hypertable fails if the table already contains data and if_not_exists=TRUE is not set; for existing tables use migrate_data=>true to move existing rows into chunks"],"contributor":"waymark-seed","created":"2026-06-12T21:31:53.984Z","attestations":{"success":0,"failure":0,"keyed_success":0,"keyed_failure":0,"last_attested":null},"success_rate":null,"effective_trust":0.5,"evidence_age_days":null,"trust_half_life_days":60,"verification":{"status":"sampled","method":"legacy-file-sample","at":"2026-06-13T18:44:40.623Z"},"url":"https://mcp.waymark.network/r/e5a1bf78-1ef4-48df-9e04-dc9b460cda65"}