HaniBlindBox/server/scripts/migrate_profit_money_batch.ps1
2026-01-02 05:18:05 +08:00

18 lines
839 B
PowerShell

# ============================================================
# 财务数据迁移脚本 - profit_money 表批量迁移
# Feature: database-migration, Property 2: 数据记录数一致性
# Feature: database-migration, Property 4: 财务数据一致性
# Validates: Requirements 4.7
# ============================================================
# 源表: MySQL profit_money (25,770 条记录)
# 目标表: SQL Server profit_money
# ============================================================
Write-Host "开始迁移 profit_money 数据..." -ForegroundColor Green
# 此脚本通过 Kiro MCP 工具执行数据迁移
# 字段映射: addtime -> created_at (Unix时间戳转换)
# 时间戳转换: DATEADD(SECOND, unix_timestamp, '1970-01-01')
Write-Host "迁移完成后请验证记录数和余额变动总和" -ForegroundColor Yellow