迁移日志文件: migration_log_20250923_132621.txt 连接成功: SQLite(db.sqlite3) → PostgreSQL(wmsdb) 是否在迁移前清空 PostgreSQL 数据库? 1. 清空所有数据 (确保无重复) 2. 不清空 (可能产生重复数据) 3. 退出 警告: 此操作将清空 PostgreSQL 数据库中的所有数据! 已清空表: django_migrations 已清空表: django_content_type 已清空表: auth_permission 已清空表: auth_group 已清空表: auth_group_permissions 已清空表: auth_user 已清空表: auth_user_groups 已清空表: auth_user_user_permissions 已清空表: django_admin_log 已清空表: bounddetail 已清空表: outbounddetail 已清空表: batchlog 已清空表: boundlist 已清空表: task 已清空表: container_detail 已清空表: container_list 已清空表: container_wcs 已清空表: allocation_pre 已清空表: erp_inboundbill 已清空表: erp_outboundbill 已清空表: erp_materialdetail 已清空表: erp_outmaterialdetail 已清空表: base_location 已清空表: location 已清空表: location_container_link 已清空表: location_change_log 已清空表: allocation_history 已清空表: location_group 已清空表: location_group_location_items 已清空表: device 已清空表: boundbatch 已清空表: outbatch 已清空表: materialstatistics 已清空表: outbounddemand 已清空表: container_operation 已清空表: out_batch_detail 已清空表: container_detail_log 已清空表: batch_log_from_container_log_detail_logs 已清空表: batch_log_from_container_log 已清空表: material_change_history 已清空表: erp_inboundbilloperatelog 已清空表: erp_outboundbilloperatelog 已清空表: flowlist 已清空表: bigscreen 已清空表: django_session 已清空表: staff 已清空表: stafftype 已清空表: shelflist 已清空表: throttle 已清空表: user_profile 已清空表: baseset 已清空表: bound_business 已清空表: bound_code_type 已清空表: bound_status 已清空表: bound_type 已清空表: department 已清空表: warehouse 已清空表: product 成功清空 PostgreSQL 数据库中的所有数据 分析完成: 发现 50 个表, 依赖顺序已确定 开始迁移 50 个表 第 1 轮迁移尝试 准备迁移表: auth_group 表 auth_group 为空,跳过 准备迁移表: auth_user 表 auth_user 有 3 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: password: 128 字符 last_name: 150 字符 email: 254 字符 username: 150 字符 first_name: 150 字符 成功迁移 3 行数据 准备迁移表: location_container_link 检查 location_container_link 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ? location 尚未迁移 ? container_list 尚未迁移 依赖表未完全迁移,暂时跳过 location_container_link 准备迁移表: location_change_log 检查 location_change_log 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ? location 尚未迁移 ? location 尚未迁移 ? container_list 尚未迁移 依赖表未完全迁移,暂时跳过 location_change_log 准备迁移表: allocation_history 检查 allocation_history 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ? location 尚未迁移 ? location 尚未迁移 ? container_list 尚未迁移 依赖表未完全迁移,暂时跳过 allocation_history 准备迁移表: task 检查 task 的依赖表迁移状态... ? container_wcs 尚未迁移 ? container_detail 尚未迁移 ? bounddetail 尚未迁移 依赖表未完全迁移,暂时跳过 task 准备迁移表: bounddetail 检查 bounddetail 的依赖表迁移状态... ? boundlist 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 bounddetail 准备迁移表: Outbounddetail 检查 Outbounddetail 的依赖表迁移状态... ? boundlist 尚未迁移 ? boundbatch 尚未迁移 ? outbatch 尚未迁移 依赖表未完全迁移,暂时跳过 Outbounddetail 准备迁移表: container_wcs 检查 container_wcs 的依赖表迁移状态... ? boundlist 尚未迁移 ? outbatch 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 container_wcs 准备迁移表: allocation_pre 表 allocation_pre 有 219 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: batch_number: 255 字符 成功迁移 219 行数据 准备迁移表: base_location 表 base_location 有 1 行数据需要迁移 使用主键 (id) 处理冲突 成功迁移 1 行数据 准备迁移表: location_group_location_items 检查 location_group_location_items 的依赖表迁移状态... ? location 尚未迁移 ? location_group 尚未迁移 依赖表未完全迁移,暂时跳过 location_group_location_items 准备迁移表: device 检查 device 的依赖表迁移状态... ? location 尚未迁移 依赖表未完全迁移,暂时跳过 device 准备迁移表: location 表 location 有 1351 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: warehouse_code: 255 字符 warehouse_name: 255 字符 shelf_type: 255 字符 location_code: 20 字符 location_group: 20 字符 location_type: 3 字符 status: 20 字符 coordinate: 50 字符 成功迁移 1351 行数据 准备迁移表: outbatch 检查 outbatch 的依赖表迁移状态... ? boundlist 尚未迁移 ? erp_outmaterialdetail 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 outbatch 准备迁移表: outbounddemand 检查 outbounddemand 的依赖表迁移状态... ? boundlist 尚未迁移 依赖表未完全迁移,暂时跳过 outbounddemand 准备迁移表: out_batch_detail 检查 out_batch_detail 的依赖表迁移状态... ? boundlist 尚未迁移 ? container_detail 尚未迁移 ? container_list 尚未迁移 依赖表未完全迁移,暂时跳过 out_batch_detail 准备迁移表: batch_log_from_container_log_detail_logs 检查 batch_log_from_container_log_detail_logs 的依赖表迁移状态... ? container_detail_log 尚未迁移 ? batch_log_from_container_log 尚未迁移 依赖表未完全迁移,暂时跳过 batch_log_from_container_log_detail_logs 准备迁移表: material_change_history 检查 material_change_history 的依赖表迁移状态... ? materialstatistics 尚未迁移 ? batch_log_from_container_log 尚未迁移 依赖表未完全迁移,暂时跳过 material_change_history 准备迁移表: batch_log_from_container_log 检查 batch_log_from_container_log 的依赖表迁移状态... ? boundlist 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 batch_log_from_container_log 准备迁移表: boundlist 检查 boundlist 的依赖表迁移状态... ? erp_outboundbill 尚未迁移 ? erp_inboundbill 尚未迁移 依赖表未完全迁移,暂时跳过 boundlist 准备迁移表: erp_inboundbilloperatelog 检查 erp_inboundbilloperatelog 的依赖表迁移状态... ? erp_inboundbill 尚未迁移 依赖表未完全迁移,暂时跳过 erp_inboundbilloperatelog 准备迁移表: erp_outboundbilloperatelog 检查 erp_outboundbilloperatelog 的依赖表迁移状态... ? erp_outboundbill 尚未迁移 依赖表未完全迁移,暂时跳过 erp_outboundbilloperatelog 准备迁移表: staff 表 staff 有 3 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: staff_name: 255 字符 staff_type: 255 字符 appid: 100 字符 openid: 255 字符 成功迁移 3 行数据 准备迁移表: stafftype 表 stafftype 有 7 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: staff_type: 255 字符 openid: 255 字符 creater: 255 字符 成功迁移 7 行数据 准备迁移表: throttle 表 throttle 有 4 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: appid: 255 字符 method: 18 字符 t_code: 255 字符 ip: 255 字符 openid: 255 字符 成功迁移 4 行数据 准备迁移表: user_profile 表 user_profile 有 3 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: name: 80 字符 t_code: 100 字符 openid: 100 字符 appid: 100 字符 ip: 100 字符 avatar: 100 字符 成功迁移 3 行数据 准备迁移表: baseset 表 baseset 有 2 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: set_name: 255 字符 set_value: 9999 字符 set_desc: 255 字符 成功迁移 2 行数据 准备迁移表: bound_business 表 bound_business 有 1 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: openid: 255 字符 bound_bs_code: 255 字符 bound_bs_name: 255 字符 creater: 255 字符 成功迁移 1 行数据 准备迁移表: bound_code_type 表 bound_code_type 有 1 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: openid: 255 字符 bound_code_type_code: 255 字符 bound_code_type_name: 255 字符 creater: 255 字符 成功迁移 1 行数据 准备迁移表: bound_status 表 bound_status 有 3 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: bound_status_name: 255 字符 creater: 255 字符 openid: 255 字符 成功迁移 3 行数据 准备迁移表: bound_type 表 bound_type 有 1 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: openid: 255 字符 bound_type_code: 255 字符 bound_type_name: 255 字符 creater: 255 字符 成功迁移 1 行数据 准备迁移表: department 表 department 有 37 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: department_manager: 255 字符 creater: 255 字符 openid: 255 字符 department_code: 255 字符 department_name: 255 字符 department_contact: 255 字符 成功迁移 37 行数据 准备迁移表: warehouse 表 warehouse 有 1 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: warehouse_address: 255 字符 warehouse_contact: 255 字符 warehouse_manager: 255 字符 creater: 255 字符 openid: 255 字符 warehouse_code: 255 字符 warehouse_name: 255 字符 warehouse_city: 255 字符 成功迁移 1 行数据 准备迁移表: product 表 product 有 196 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: product_name: 255 字符 product_std: 255 字符 product_unit: 255 字符 product_package: 255 字符 creater: 255 字符 product_code: 255 字符 成功迁移 196 行数据 准备迁移表: location_group 表 location_group 有 321 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: warehouse_code: 50 字符 group_name: 50 字符 group_type: 50 字符 group_code: 50 字符 current_batch: 50 字符 status: 20 字符 current_goods_code: 50 字符 成功迁移 321 行数据 准备迁移表: batchlog 检查 batchlog 的依赖表迁移状态... ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 batchlog 准备迁移表: container_detail_log 检查 container_detail_log 的依赖表迁移状态... ? container_detail 尚未迁移 依赖表未完全迁移,暂时跳过 container_detail_log 准备迁移表: container_detail 检查 container_detail 的依赖表迁移状态... ? container_list 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 container_detail 准备迁移表: container_operation 检查 container_operation 的依赖表迁移状态... ? container_list 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 container_operation 准备迁移表: boundbatch 检查 boundbatch 的依赖表迁移状态... ? erp_materialdetail 尚未迁移 依赖表未完全迁移,暂时跳过 boundbatch 准备迁移表: erp_outmaterialdetail 检查 erp_outmaterialdetail 的依赖表迁移状态... ? erp_outboundbill 尚未迁移 ? erp_materialdetail 尚未迁移 依赖表未完全迁移,暂时跳过 erp_outmaterialdetail 准备迁移表: erp_materialdetail 检查 erp_materialdetail 的依赖表迁移状态... ? erp_inboundbill 尚未迁移 依赖表未完全迁移,暂时跳过 erp_materialdetail 准备迁移表: erp_inboundbill 表 erp_inboundbill 有 89 行数据需要迁移 使用主键 (billId) 处理冲突 字段长度限制: number: 50 字符 erp_audit_id: 1000 字符 date: 50 字符 department: 100 字符 warehouse: 100 字符 creater: 50 字符 erp_save_id: 1000 字符 成功迁移 89 行数据 准备迁移表: erp_outboundbill 表 erp_outboundbill 有 124 行数据需要迁移 使用主键 (billId) 处理冲突 字段长度限制: number: 50 字符 erp_audit_id: 1000 字符 date: 50 字符 department: 10 字符 warehouse: 10 字符 creater: 50 字符 erp_save_id: 1000 字符 成功迁移 124 行数据 准备迁移表: flowlist 表 flowlist 有 189 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: iout_type: 255 字符 department: 255 字符 warehouse_code: 20 字符 warehouse_name: 255 字符 goods_code: 255 字符 goods_desc: 255 字符 goods_std: 255 字符 goods_batch: 255 字符 in_batch: 255 字符 out_batch: 255 字符 goods_unit: 255 字符 goods_notes: 255 字符 creator: 255 字符 document_number: 20 字符 document_type: 20 字符 business_type: 20 字符 成功迁移 189 行数据 准备迁移表: shelflist 表 shelflist 为空,跳过 准备迁移表: materialstatistics 表 materialstatistics 有 18 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: goods_unit: 255 字符 goods_std: 255 字符 goods_code: 255 字符 goods_desc: 255 字符 成功迁移 18 行数据 准备迁移表: bigscreen 表 bigscreen 有 30 行数据需要迁移 使用主键 (id) 处理冲突 成功迁移 30 行数据 准备迁移表: container_list 表 container_list 有 354 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: current_location: 50 字符 target_location: 50 字符 成功迁移 354 行数据 本轮迁移后仍有 25 个表未成功迁移 第 2 轮迁移尝试 准备迁移表: location_container_link 检查 location_container_link 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_container_link 准备迁移表: location_change_log 检查 location_change_log 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_change_log 准备迁移表: allocation_history 检查 allocation_history 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 allocation_history 准备迁移表: task 检查 task 的依赖表迁移状态... ? container_wcs 尚未迁移 ? container_detail 尚未迁移 ? bounddetail 尚未迁移 依赖表未完全迁移,暂时跳过 task 准备迁移表: bounddetail 检查 bounddetail 的依赖表迁移状态... ? boundlist 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 bounddetail 准备迁移表: Outbounddetail 检查 Outbounddetail 的依赖表迁移状态... ? boundlist 尚未迁移 ? boundbatch 尚未迁移 ? outbatch 尚未迁移 依赖表未完全迁移,暂时跳过 Outbounddetail 准备迁移表: container_wcs 检查 container_wcs 的依赖表迁移状态... ? boundlist 尚未迁移 ? outbatch 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 container_wcs 准备迁移表: location_group_location_items 检查 location_group_location_items 的依赖表迁移状态... ✓ location 已迁移 ✓ location_group 已迁移 表 location_group_location_items 有 1020 行数据需要迁移 使用主键 (id) 处理冲突 成功迁移 1020 行数据 准备迁移表: device 检查 device 的依赖表迁移状态... ✓ location 已迁移 表 device 有 2 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: status: 255 字符 mode: 255 字符 warehouse_code: 255 字符 device_id: 255 字符 device_name: 255 字符 device_type: 255 字符 ip_address: 255 字符 成功迁移 2 行数据 准备迁移表: outbatch 检查 outbatch 的依赖表迁移状态... ? boundlist 尚未迁移 ? erp_outmaterialdetail 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 outbatch 准备迁移表: outbounddemand 检查 outbounddemand 的依赖表迁移状态... ? boundlist 尚未迁移 依赖表未完全迁移,暂时跳过 outbounddemand 准备迁移表: out_batch_detail 检查 out_batch_detail 的依赖表迁移状态... ? boundlist 尚未迁移 ? container_detail 尚未迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 out_batch_detail 准备迁移表: batch_log_from_container_log_detail_logs 检查 batch_log_from_container_log_detail_logs 的依赖表迁移状态... ? container_detail_log 尚未迁移 ? batch_log_from_container_log 尚未迁移 依赖表未完全迁移,暂时跳过 batch_log_from_container_log_detail_logs 准备迁移表: material_change_history 检查 material_change_history 的依赖表迁移状态... ✓ materialstatistics 已迁移 ? batch_log_from_container_log 尚未迁移 依赖表未完全迁移,暂时跳过 material_change_history 准备迁移表: batch_log_from_container_log 检查 batch_log_from_container_log 的依赖表迁移状态... ? boundlist 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 batch_log_from_container_log 准备迁移表: boundlist 检查 boundlist 的依赖表迁移状态... ✓ erp_outboundbill 已迁移 ✓ erp_inboundbill 已迁移 表 boundlist 有 260 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: openid: 255 字符 bound_status: 255 字符 note: 255 字符 bound_month: 255 字符 creater: 255 字符 bound_code: 255 字符 bound_code_type: 255 字符 bound_bs_type: 255 字符 bound_type: 255 字符 bound_desc: 255 字符 bound_department: 255 字符 成功迁移 260 行数据 准备迁移表: erp_inboundbilloperatelog 检查 erp_inboundbilloperatelog 的依赖表迁移状态... ✓ erp_inboundbill 已迁移 表 erp_inboundbilloperatelog 有 253 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: log_type: 20 字符 成功迁移 253 行数据 准备迁移表: erp_outboundbilloperatelog 检查 erp_outboundbilloperatelog 的依赖表迁移状态... ✓ erp_outboundbill 已迁移 表 erp_outboundbilloperatelog 有 180 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: log_type: 20 字符 成功迁移 180 行数据 准备迁移表: batchlog 检查 batchlog 的依赖表迁移状态... ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 batchlog 准备迁移表: container_detail_log 检查 container_detail_log 的依赖表迁移状态... ? container_detail 尚未迁移 依赖表未完全迁移,暂时跳过 container_detail_log 准备迁移表: container_detail 检查 container_detail 的依赖表迁移状态... ✓ container_list 已迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 container_detail 准备迁移表: container_operation 检查 container_operation 的依赖表迁移状态... ✓ container_list 已迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 container_operation 准备迁移表: boundbatch 检查 boundbatch 的依赖表迁移状态... ? erp_materialdetail 尚未迁移 依赖表未完全迁移,暂时跳过 boundbatch 准备迁移表: erp_outmaterialdetail 检查 erp_outmaterialdetail 的依赖表迁移状态... ✓ erp_outboundbill 已迁移 ? erp_materialdetail 尚未迁移 依赖表未完全迁移,暂时跳过 erp_outmaterialdetail 准备迁移表: erp_materialdetail 检查 erp_materialdetail 的依赖表迁移状态... ✓ erp_inboundbill 已迁移 表 erp_materialdetail 有 130 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: material_goods_code: 20 字符 production_batch: 50 字符 goods_code: 20 字符 goods_name: 100 字符 goods_std: 50 字符 goods_unit: 20 字符 material_batch_order: 20 字符 成功迁移 130 行数据 本轮迁移后仍有 19 个表未成功迁移 第 3 轮迁移尝试 准备迁移表: location_container_link 检查 location_container_link 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_container_link 准备迁移表: location_change_log 检查 location_change_log 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_change_log 准备迁移表: allocation_history 检查 allocation_history 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 allocation_history 准备迁移表: task 检查 task 的依赖表迁移状态... ? container_wcs 尚未迁移 ? container_detail 尚未迁移 ? bounddetail 尚未迁移 依赖表未完全迁移,暂时跳过 task 准备迁移表: bounddetail 检查 bounddetail 的依赖表迁移状态... ✓ boundlist 已迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 bounddetail 准备迁移表: Outbounddetail 检查 Outbounddetail 的依赖表迁移状态... ✓ boundlist 已迁移 ? boundbatch 尚未迁移 ? outbatch 尚未迁移 依赖表未完全迁移,暂时跳过 Outbounddetail 准备迁移表: container_wcs 检查 container_wcs 的依赖表迁移状态... ✓ boundlist 已迁移 ? outbatch 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 container_wcs 准备迁移表: outbatch 检查 outbatch 的依赖表迁移状态... ✓ boundlist 已迁移 ? erp_outmaterialdetail 尚未迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 outbatch 准备迁移表: outbounddemand 检查 outbounddemand 的依赖表迁移状态... ✓ boundlist 已迁移 表 outbounddemand 为空,跳过 准备迁移表: out_batch_detail 检查 out_batch_detail 的依赖表迁移状态... ✓ boundlist 已迁移 ? container_detail 尚未迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 out_batch_detail 准备迁移表: batch_log_from_container_log_detail_logs 检查 batch_log_from_container_log_detail_logs 的依赖表迁移状态... ? container_detail_log 尚未迁移 ? batch_log_from_container_log 尚未迁移 依赖表未完全迁移,暂时跳过 batch_log_from_container_log_detail_logs 准备迁移表: material_change_history 检查 material_change_history 的依赖表迁移状态... ✓ materialstatistics 已迁移 ? batch_log_from_container_log 尚未迁移 依赖表未完全迁移,暂时跳过 material_change_history 准备迁移表: batch_log_from_container_log 检查 batch_log_from_container_log 的依赖表迁移状态... ✓ boundlist 已迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 batch_log_from_container_log 准备迁移表: batchlog 检查 batchlog 的依赖表迁移状态... ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 batchlog 准备迁移表: container_detail_log 检查 container_detail_log 的依赖表迁移状态... ? container_detail 尚未迁移 依赖表未完全迁移,暂时跳过 container_detail_log 准备迁移表: container_detail 检查 container_detail 的依赖表迁移状态... ✓ container_list 已迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 container_detail 准备迁移表: container_operation 检查 container_operation 的依赖表迁移状态... ✓ container_list 已迁移 ? boundbatch 尚未迁移 依赖表未完全迁移,暂时跳过 container_operation 准备迁移表: boundbatch 检查 boundbatch 的依赖表迁移状态... ✓ erp_materialdetail 已迁移 表 boundbatch 有 221 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: bound_number: 255 字符 bound_month: 255 字符 goods_package: 255 字符 warehouse_code: 255 字符 warehouse_name: 255 字符 goods_code: 255 字符 goods_desc: 255 字符 goods_std: 255 字符 goods_unit: 255 字符 check_user: 255 字符 note: 255 字符 creater: 255 字符 openid: 255 字符 sourced_number: 255 字符 成功迁移 221 行数据 准备迁移表: erp_outmaterialdetail 检查 erp_outmaterialdetail 的依赖表迁移状态... ✓ erp_outboundbill 已迁移 ✓ erp_materialdetail 已迁移 表 erp_outmaterialdetail 有 163 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: material_goods_code: 20 字符 production_batch: 50 字符 goods_code: 20 字符 goods_name: 100 字符 goods_unit: 20 字符 material_batch_order: 20 字符 成功迁移 163 行数据 本轮迁移后仍有 16 个表未成功迁移 第 4 轮迁移尝试 准备迁移表: location_container_link 检查 location_container_link 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_container_link 准备迁移表: location_change_log 检查 location_change_log 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_change_log 准备迁移表: allocation_history 检查 allocation_history 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 allocation_history 准备迁移表: task 检查 task 的依赖表迁移状态... ? container_wcs 尚未迁移 ? container_detail 尚未迁移 ? bounddetail 尚未迁移 依赖表未完全迁移,暂时跳过 task 准备迁移表: bounddetail 检查 bounddetail 的依赖表迁移状态... ✓ boundlist 已迁移 ✓ boundbatch 已迁移 表 bounddetail 有 221 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: detail_code: 255 字符 creater: 255 字符 openid: 255 字符 成功迁移 221 行数据 准备迁移表: Outbounddetail 检查 Outbounddetail 的依赖表迁移状态... ✓ boundlist 已迁移 ✓ boundbatch 已迁移 ? outbatch 尚未迁移 依赖表未完全迁移,暂时跳过 Outbounddetail 准备迁移表: container_wcs 检查 container_wcs 的依赖表迁移状态... ✓ boundlist 已迁移 ? outbatch 尚未迁移 ✓ boundbatch 已迁移 依赖表未完全迁移,暂时跳过 container_wcs 准备迁移表: outbatch 检查 outbatch 的依赖表迁移状态... ✓ boundlist 已迁移 ✓ erp_outmaterialdetail 已迁移 ✓ boundbatch 已迁移 表 outbatch 有 191 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: out_number: 255 字符 creater: 255 字符 openid: 255 字符 out_note: 255 字符 warehouse_code: 255 字符 warehouse_name: 255 字符 goods_code: 255 字符 goods_desc: 255 字符 goods_std: 255 字符 goods_unit: 255 字符 成功迁移 191 行数据 准备迁移表: out_batch_detail 检查 out_batch_detail 的依赖表迁移状态... ✓ boundlist 已迁移 ? container_detail 尚未迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 out_batch_detail 准备迁移表: batch_log_from_container_log_detail_logs 检查 batch_log_from_container_log_detail_logs 的依赖表迁移状态... ? container_detail_log 尚未迁移 ? batch_log_from_container_log 尚未迁移 依赖表未完全迁移,暂时跳过 batch_log_from_container_log_detail_logs 准备迁移表: material_change_history 检查 material_change_history 的依赖表迁移状态... ✓ materialstatistics 已迁移 ? batch_log_from_container_log 尚未迁移 依赖表未完全迁移,暂时跳过 material_change_history 准备迁移表: batch_log_from_container_log 检查 batch_log_from_container_log 的依赖表迁移状态... ✓ boundlist 已迁移 ✓ boundbatch 已迁移 表 batch_log_from_container_log 有 203 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: log_type: 20 字符 goods_code: 50 字符 goods_desc: 100 字符 goods_unit: 50 字符 goods_std: 50 字符 成功迁移 203 行数据 准备迁移表: batchlog 检查 batchlog 的依赖表迁移状态... ✓ boundbatch 已迁移 表 batchlog 有 2555 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: goods_code: 255 字符 goods_desc: 255 字符 openid: 255 字符 log_content: 255 字符 creater: 255 字符 成功迁移 2555 行数据 准备迁移表: container_detail_log 检查 container_detail_log 的依赖表迁移状态... ? container_detail 尚未迁移 依赖表未完全迁移,暂时跳过 container_detail_log 准备迁移表: container_detail 检查 container_detail 的依赖表迁移状态... ✓ container_list 已迁移 ✓ boundbatch 已迁移 表 container_detail 有 7413 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: goods_code: 50 字符 goods_desc: 100 字符 creater: 50 字符 成功迁移 7413 行数据 准备迁移表: container_operation 检查 container_operation 的依赖表迁移状态... ✓ container_list 已迁移 ✓ boundbatch 已迁移 表 container_operation 有 1534 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: operation_type: 20 字符 goods_code: 50 字符 goods_desc: 100 字符 from_location: 50 字符 to_location: 50 字符 operator: 50 字符 成功迁移 1534 行数据 本轮迁移后仍有 10 个表未成功迁移 第 5 轮迁移尝试 准备迁移表: location_container_link 检查 location_container_link 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_container_link 准备迁移表: location_change_log 检查 location_change_log 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_change_log 准备迁移表: allocation_history 检查 allocation_history 的依赖表迁移状态... ? container_wcs 尚未迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 allocation_history 准备迁移表: task 检查 task 的依赖表迁移状态... ? container_wcs 尚未迁移 ✓ container_detail 已迁移 ✓ bounddetail 已迁移 依赖表未完全迁移,暂时跳过 task 准备迁移表: Outbounddetail 检查 Outbounddetail 的依赖表迁移状态... ✓ boundlist 已迁移 ✓ boundbatch 已迁移 ✓ outbatch 已迁移 表 Outbounddetail 有 191 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: detail_code: 255 字符 creater: 255 字符 openid: 255 字符 成功迁移 191 行数据 准备迁移表: container_wcs 检查 container_wcs 的依赖表迁移状态... ✓ boundlist 已迁移 ✓ outbatch 已迁移 ✓ boundbatch 已迁移 表 container_wcs 有 1242 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: taskid: 50 字符 tasktype: 50 字符 batch_number: 50 字符 container: 50 字符 current_location: 50 字符 target_location: 50 字符 成功迁移 1242 行数据 准备迁移表: out_batch_detail 检查 out_batch_detail 的依赖表迁移状态... ✓ boundlist 已迁移 ✓ container_detail 已迁移 ✓ container_list 已迁移 表 out_batch_detail 有 3686 行数据需要迁移 使用主键 (id) 处理冲突 成功迁移 3686 行数据 准备迁移表: batch_log_from_container_log_detail_logs 检查 batch_log_from_container_log_detail_logs 的依赖表迁移状态... ? container_detail_log 尚未迁移 ✓ batch_log_from_container_log 已迁移 依赖表未完全迁移,暂时跳过 batch_log_from_container_log_detail_logs 准备迁移表: material_change_history 检查 material_change_history 的依赖表迁移状态... ✓ materialstatistics 已迁移 ✓ batch_log_from_container_log 已迁移 表 material_change_history 有 203 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: goods_code: 50 字符 goods_desc: 100 字符 goods_std: 50 字符 goods_unit: 50 字符 change_type: 20 字符 成功迁移 203 行数据 准备迁移表: container_detail_log 检查 container_detail_log 的依赖表迁移状态... ✓ container_detail 已迁移 表 container_detail_log 有 10453 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: log_type: 20 字符 creater: 50 字符 成功迁移 10453 行数据 本轮迁移后仍有 5 个表未成功迁移 第 6 轮迁移尝试 准备迁移表: location_container_link 检查 location_container_link 的依赖表迁移状态... ✓ container_wcs 已迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_container_link 准备迁移表: location_change_log 检查 location_change_log 的依赖表迁移状态... ✓ container_wcs 已迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 location_change_log 准备迁移表: allocation_history 检查 allocation_history 的依赖表迁移状态... ✓ container_wcs 已迁移 ? task 尚未迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 依赖表未完全迁移,暂时跳过 allocation_history 准备迁移表: task 检查 task 的依赖表迁移状态... ✓ container_wcs 已迁移 ✓ container_detail 已迁移 ✓ bounddetail 已迁移 表 task 有 18734 行数据需要迁移 使用主键 (id) 处理冲突 成功迁移 18734 行数据 准备迁移表: batch_log_from_container_log_detail_logs 检查 batch_log_from_container_log_detail_logs 的依赖表迁移状态... ✓ container_detail_log 已迁移 ✓ batch_log_from_container_log 已迁移 表 batch_log_from_container_log_detail_logs 有 4948 行数据需要迁移 使用主键 (id) 处理冲突 成功迁移 4948 行数据 本轮迁移后仍有 3 个表未成功迁移 第 7 轮迁移尝试 准备迁移表: location_container_link 检查 location_container_link 的依赖表迁移状态... ✓ container_wcs 已迁移 ✓ task 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 表 location_container_link 有 374 行数据需要迁移 使用主键 (id) 处理冲突 字段长度限制: operator: 50 字符 成功迁移 374 行数据 准备迁移表: location_change_log 检查 location_change_log 的依赖表迁移状态... ✓ container_wcs 已迁移 ✓ task 已迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 表 location_change_log 为空,跳过 准备迁移表: allocation_history 检查 allocation_history 的依赖表迁移状态... ✓ container_wcs 已迁移 ✓ task 已迁移 ✓ location 已迁移 ✓ location 已迁移 ✓ container_list 已迁移 表 allocation_history 为空,跳过 所有表迁移成功! 日志文件已保存: migration_log_20250923_132621.txt