为了更快的定位您的问题,请提供以下信息,谢谢
【详述】问题详细描述
【背景】做过哪些操作? Starrrocks集群从3.1.13 升级到3.2.10 ,升级前做过所有物化视图 ALTER MATERIALIZED VIEW xxx INACTIVE; 但升级后,出现3张dim表(基表是starrocks内表,由datax1小时从业务库(postgresql)同步一次)出现不能手动设置ACTIVE情况.为使第一时间给到业务方,选择删除后重新创建,此时报错:Create/Rebuild materialized view from inactive materialized view:xxx(不能创建的物化视图名称.)
下午本人继续重试(间隔3小时),发现能创建物化视图.
【业务影响】出现几张物化视图异常(不能ALTER MATERIALIZED VIEW xxx ACTIVE;操作.)
【是否存算分离】存算一体
【StarRocks版本】例如:3.2.10
【集群规模】例如:3fe(2 follower+1leader)+3be(fe与be混部)
【机器信息】CPU虚拟核/内存/网卡,例如:16C/64G/万兆
【联系方式】yaoquanxin@xueji.com
【附件】
问题物化视图表结构:
CREATE MATERIALIZED VIEW dim_ctk_smartretail_tenant_org
comment “DIM-机构档案”
DISTRIBUTED BY HASH(id)
REFRESH ASYNC START(“2024-08-17 05:00:00”) EVERY (INTERVAL 1 hour)
AS
select
id COMMENT ‘ID’,
Parent_Id COMMENT ‘父ID’,
Level COMMENT ‘层级’,
Is_Last_Level COMMENT ‘是否末级’,
Id_Path COMMENT ‘ID路径’,
code COMMENT ‘机构编码’,
name COMMENT ‘机构名称’,
short_name COMMENT ‘机构简称’,
org_type_id COMMENT ‘机构类型’,
py_code COMMENT ‘助记码’,
open_on COMMENT ‘开业/引进日期’,
store_type_id COMMENT ‘门店类型’,
dc_id COMMENT ‘默认配送’,
Logistics_Type_Id COMMENT ‘物流方式’,
group_id COMMENT ‘机构分组’,
province_id COMMENT ‘省’,
city_Id COMMENT ‘市’,
district_id COMMENT ‘区县’,
Street_Id COMMENT ‘街道’,
address COMMENT ‘详细地址’,
legal_person COMMENT ‘法人姓名’,
manager COMMENT ‘负责人’,
manager1 COMMENT ‘联系人1’,
Telephone1 COMMENT ‘联系电话1’,
manager2 COMMENT ‘联系人2’,
Telephone2 COMMENT ‘联系电话2’,
fax COMMENT ‘传真’,
email COMMENT ‘邮箱’,
floor COMMENT ‘经营楼层’,
area COMMENT ‘面积’,
org_id1 COMMENT ‘一级机构Id’,
org_code1 COMMENT ‘一级机构编码’,
org_id2 COMMENT ‘二级机构id’,
org_code2 COMMENT ‘二级机构编码’,
org_id3 COMMENT ‘三级机构id’,
org_code3 COMMENT ‘三级机构编码’,
org_id4 COMMENT ‘四级机构id’,
org_code4 COMMENT ‘四级机构编码’,
employee_count COMMENT ‘员工数’,
manage_type_id COMMENT ‘供应商管理类型’,
supplier_category_id COMMENT ‘供应商分类’,
business_type_id COMMENT ‘供应商经营方式’,
settlement_period_id COMMENT ‘账期类型’,
settlement_days COMMENT ‘结算天数’,
business_scope COMMENT ‘经营范围’,
tax_no COMMENT ‘企业税务登记号’,
bank COMMENT ‘开户银行’,
bank_account COMMENT ‘开户行’,
bank_account_name COMMENT ‘银行帐户名’,
credit_amt COMMENT ‘信用额度(MIS初始化,后续从pay同步过来)’,
account_amt COMMENT ‘帐户余额(MIS初始化,后续从pay同步过来)’,
sale_date COMMENT ‘当前日结日期’,
enable_scm COMMENT ‘是否启用SCM’,
enable_contract COMMENT ‘是否启用合同’,
seq_no COMMENT ‘排序’,
status COMMENT ‘状态’,
description COMMENT ‘备注’,
create_code COMMENT ‘创建人工号’,
create_name COMMENT ‘创建人名称’,
create_on COMMENT ‘创建时间’,
modify_code COMMENT ‘修改人工号’,
modify_name COMMENT ‘修改人名称’,
modify_on COMMENT ‘修改时间’,
id_card COMMENT ‘供应商身份证号码’,
voucher_account_code COMMENT ‘财务凭证-主体账簿编码’,
account_day COMMENT ‘拦账日’,
register_address COMMENT ‘注册地址’,
contract_id COMMENT ‘合同ID’,
contract_code COMMENT ‘合同编码’,
arrearage_amt COMMENT ‘欠款额度(MIS初始化,后续从pay同步过来)’,
enable_replenishment_quota COMMENT ‘启用补货配额控制:0=不启用/1=启用’,
enable_dispatch_quota COMMENT ‘启用出库配额控制:0=不启用/1=启用’,
require_quotation_type COMMENT ‘补货配额控制类型’,
franchisee_type_id COMMENT ‘加盟商类型’,
enable_loss_amt_limit COMMENT ‘启用报损额度控制:0=不启用(默认值)/1=启用’,
loss_amt_limit_policy COMMENT ‘报损额度控制策略:1=按自然日/2=按自然月’,
pay_day COMMENT ‘付款天数’,
enable_order COMMENT ‘是否参与业务单据:0=否,1=是’,
enable_payment COMMENT ‘是否参与费用单据:0=否,1=是’,
body_policy_id COMMENT ‘对账主体策略,参照表:cw_statement_body_policy’,
sale_rate COMMENT ‘销售扣点’,
check_goods_relation COMMENT ‘校验供货关系’,
enable_mandatory_invoice COMMENT ‘结算是否管控发票:0=否(默认值),1=是’,
manual_code COMMENT ‘手工编码’,
enable_recharge_amt COMMENT ‘启用充值金额控制:0=不启用/1=启用’,
settle_style COMMENT ‘结算方式,详见:zd_settle_style’,
advance_type_id COMMENT ‘预付款标识’,
settle_level_id COMMENT ‘结算层级’,
js_id COMMENT ‘结算主体编码’,
invoice_title COMMENT ‘发票抬头’,
bank_no COMMENT ‘联行号’,
is_inner_supplier COMMENT ‘是否内部供应商’,
purchase_id COMMENT ‘采购员ID’,
purchase_code COMMENT ‘采购员编码’,
owner_org_id COMMENT ‘做单机构ID’,
owner_org_code COMMENT ‘做单机构编码’,
purchase_level COMMENT ‘采购级别’,
customer_id COMMENT ‘机构对应的客户编号’,
customer_code COMMENT ‘机构对应的客户编码’,
as_id COMMENT ‘核算主体编码’,
enable_financial_review COMMENT ‘是否参与财务核对:0=否,1=是’,
last_settle_period_date COMMENT ‘最晚对账期间截止日期’,
shop_area_id COMMENT ‘机构商圈编码’,
city_level_id COMMENT ‘城市级别编码’,
price_group_id COMMENT ‘机构定价分组编码’,
out_tax_type COMMENT ‘纳税人类型,0=一般纳税人,1=非一般纳税人’,
out_tax COMMENT ‘销项税率’,
base_amt_remind COMMENT ‘本金不足是否短信提醒’,
is_real_rj COMMENT ‘是否已真正日结’,
company_code COMMENT ‘公司代码’,
first_sale_date COMMENT ‘首销日期’,
last_sale_date COMMENT ‘末销日期’
FROM ods_ctk_smartretail_tenant_zd_org;