Alter a hypertable
You can alter a hypertable, for example to add a column, by using a standard
ALTER TABLE command. This works for both regular and
In the following example, the hypertable is named
conditions and the new
column is named
ALTER TABLE conditions ADD COLUMN humidity DOUBLE PRECISION NULL;
Adding a column is efficient so long as you set its default value to
NULL. If you set the default to a non-null value, it takes longer, because TimescaleDB needs to fill in this value for all existing rows of all existing chunks.
Found an issue on this page?Report an issue!