CREATE TABLE segments (
    id bigserial PRIMARY KEY,
    business_id bigint NOT NULL REFERENCES businesses(id),
    name text NOT NULL,
    cdp_id bigint NOT NULL,
    cdp_size bigint NOT NULL,
    created_at timestamptz DEFAULT now()
);
CREATE INDEX segments_biz_id_btree_idx ON segments USING btree (business_id);
