CREATE TABLE promocode_account_links (
    history_event_id BIGSERIAL PRIMARY KEY,
    history_user_id text NOT NULL,
    history_originator_id text,
    history_action text NOT NULL,
    history_timestamp integer NOT NULL,
    history_comment text,

    promocode text NOT NULL,
    account_id bigint NOT NULL,
    user_id text,

    FOREIGN KEY(account_id) REFERENCES "billing_account"(account_id)
)