// Table Statistic Customer Installation CREATE TABLE report.crm_statistic_customer_installation ( id_customer_installation BIGINT GENERATED BY DEFAULT AS IDENTITY PRIMARY KEY, statistic_date DATE NOT NULL, id_unit_instalasi BIGINT unit_type VARCHAR(255), done_status BIGINT, install_status BIGINT, survey_status BIGINT, pending_status BIGINT, failed_status BIGINT, uninstall_status BIGINT, blacklist_status BIGINT, block_status BIGINT, unblock_status BIGINT, created_at TIMESTAMP, updated_at TIMESTAMP, deleted_at TIMESTAMP ); CREATE INDEX idx_crm_statistic_customer_installation_date ON report.crm_statistic_customer_installation (statistic_date); // Table Statistic Customer Category CREATE TABLE report.crm_statistic_customer_category ( id_customer_category BIGINT GENERATED BY DEFAULT AS IDENTITY PRIMARY KEY, statistic_date DATE NOT NULL, unit_type VARCHAR(255), id_unit_instalasi BIGINT home_category BIGINT, corp_category BIGINT, educ_category BIGINT, gov_category BIGINT, res_category BIGINT, created_at TIMESTAMP, updated_at TIMESTAMP, deleted_at TIMESTAMP ); CREATE INDEX idx_crm_statistic_customer_category_date ON report.crm_statistic_customer_category (statistic_date);