
-- DROP TABLE tl_payment_plan;



CREATE TABLE tl_payment_plan (
    object_id int NOT NULL ,
    object_last_updated_date datetime DEFAULT getdate() NOT NULL ,
    object_created_date datetime DEFAULT getdate() NOT NULL
    ,
    stripe_reference varchar(100) NOT NULL,
    plan_name text NULL,
    description text NULL,
    currency_type varchar(200) NOT NULL,
    amount numeric(20,5) NOT NULL,
    interval varchar(200) NOT NULL,
    interval_count numeric(12) NOT NULL,
    trial_period_days numeric(12) NULL,
    active_job_count numeric(12) NULL,
    disabled char(1) NULL,
    product_reference varchar(100) NULL,
    usage_type varchar(200) NULL,
    linked_plan varchar(100) NULL
    );



ALTER TABLE tl_payment_plan ADD    
    CONSTRAINT PK_tl_payment_plan PRIMARY KEY 
    (
        object_id
    ) ;
    
    
    