Altering and updating table schemas

    note

    While you can change the schema of an existing hypertable, you cannot change the schema of a continuous aggregate. For continuous aggregates, the only permissible changes are renaming a view, setting a schema, changing the owner, and adjusting other parameters.

    This creates the new column, with all existing entries recording for the new column.

    1. ADD CONSTRAINT zipchk
    2. CHECK (char_length(zipcode) = 5);

    This scans the table to verify that existing rows meet the constraint, but does not require a table rewrite.