select subsidiary_material_id, subsidiary_material_code, hs_number, subsidiary_material_name, stock_unit_weight, specification_model, inventory_unit, dedicated_whether, customs_name, safety_stock, remarks, special_use, whether_stop, supplier_number, limit_collection_amount, subsidiary_material_category, default_warehouse, warehouse_location, purchase_price, purchase_lead_time, minimum_batch_size, supplier_code, supplier_name, limit_whether, maximum_purchase_quantity, cost_price, primary_supplier, sub_supplier, maximum_inventory, detention_days, gp_Item_selection, export_sales, creater_name, material_category, kes_number, type_machine, first_add_time, update_info_time, creater_time from sys_subsidiary_material
insert into sys_subsidiary_material
subsidiary_material_code,
hs_number,
subsidiary_material_name,
stock_unit_weight,
specification_model,
inventory_unit,
dedicated_whether,
customs_name,
safety_stock,
remarks,
special_use,
whether_stop,
supplier_number,
limit_collection_amount,
subsidiary_material_category,
default_warehouse,
warehouse_location,
purchase_price,
purchase_lead_time,
minimum_batch_size,
supplier_code,
supplier_name,
limit_whether,
maximum_purchase_quantity,
cost_price,
primary_supplier,
sub_supplier,
maximum_inventory,
detention_days,
gp_Item_selection,
export_sales,
creater_name,
material_category,
kes_number,
type_machine,
creater_time,
first_add_time,
#{subsidiaryMaterialCode},
#{hsNumber},
#{subsidiaryMaterialName},
#{stockUnitWeight},
#{specificationModel},
#{inventoryUnit},
#{dedicatedWhether},
#{customsName},
#{safetyStock},
#{remarks},
#{specialUse},
#{whetherStop},
#{supplierNumber},
#{limitCollectionAmount},
#{subsidiaryMaterialCategory},
#{defaultWarehouse},
#{warehouseLocation},
#{purchasePrice},
#{purchaseLeadTime},
#{minimumBatchSize},
#{supplierCode},
#{supplierName},
#{limitWhether},
#{maximumPurchaseQuantity},
#{costPrice},
#{primarySupplier},
#{subSupplier},
#{maximumInventory},
#{detentionDays},
#{gpItemSelection},
#{exportSales},
#{createrName},
#{materialCategory},
#{kesNumber},
#{typeMachine},
#{createrTime},
now(),
update sys_subsidiary_material
subsidiary_material_code = #{subsidiaryMaterialCode},
hs_number = #{hsNumber},
subsidiary_material_name = #{subsidiaryMaterialName},
stock_unit_weight = #{stockUnitWeight},
specification_model = #{specificationModel},
inventory_unit = #{inventoryUnit},
dedicated_whether = #{dedicatedWhether},
customs_name = #{customsName},
safety_stock = #{safetyStock},
remarks = #{remarks},
special_use = #{specialUse},
whether_stop = #{whetherStop},
supplier_number = #{supplierNumber},
limit_collection_amount = #{limitCollectionAmount},
subsidiary_material_category = #{subsidiaryMaterialCategory},
default_warehouse = #{defaultWarehouse},
warehouse_location = #{warehouseLocation},
purchase_price = #{purchasePrice},
purchase_lead_time = #{purchaseLeadTime},
minimum_batch_size = #{minimumBatchSize},
supplier_code = #{supplierCode},
supplier_name = #{supplierName},
limit_whether = #{limitWhether},
maximum_purchase_quantity = #{maximumPurchaseQuantity},
cost_price = #{costPrice},
primary_supplier = #{primarySupplier},
sub_supplier = #{subSupplier},
maximum_inventory = #{maximumInventory},
detention_days = #{detentionDays},
gp_Item_selection = #{gpItemSelection},
export_sales = #{exportSales},
creater_name = #{createrName},
material_category = #{materialCategory},
kes_number = #{kesNumber},
type_machine = #{typeMachine},
creater_time = #{createrTime},
update_info_time = CONCAT_WS(',',NOW(),update_info_time),
where subsidiary_material_id = #{subsidiaryMaterialId}
delete from sys_subsidiary_material where subsidiary_material_id = #{subsidiaryMaterialId}
delete from sys_subsidiary_material where subsidiary_material_id in
#{subsidiaryMaterialId}