
ALTER TABLE yy_sysrole ADD PRIMARY KEY (id);
ALTER TABLE yy_sysrole MODIFY id BIGINT NOT NULL AUTO_INCREMENT;


ALTER TABLE yy_sysrolechannelmapping ADD temp_id BIGINT AUTO_INCREMENT PRIMARY KEY FIRST;
UPDATE yy_sysrolechannelmapping SET id = temp_id;
ALTER TABLE yy_sysrolechannelmapping DROP temp_id;
ALTER TABLE yy_sysrolechannelmapping ADD PRIMARY KEY (id);
ALTER TABLE yy_sysrolechannelmapping MODIFY id BIGINT NOT NULL AUTO_INCREMENT;

ALTER TABLE PurchasePlanDetails ADD Order_item_id BIGINT DEFAULT NULL COMMENT "关联 purchasematerial 的 ID， 订单明细 ID";