Files
feiqiu-ETL/scripts/backfill_202507_to_now.bat
2026-02-04 21:39:01 +08:00

46 lines
1.2 KiB
Batchfile
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
@echo off
REM 数据补全脚本:从 2025-07-01 到当前日期
REM 用法:直接运行此脚本
cd /d %~dp0..
echo ====================================
echo 数据补全2025-07-01 到现在
echo ====================================
echo.
echo 开始时间:%date% %time%
echo.
REM 设置时间窗口
set WINDOW_START=2025-07-01 00:00:00
set WINDOW_END=2026-02-03 00:00:00
echo 时间窗口:%WINDOW_START% ~ %WINDOW_END%
echo.
REM 执行 ODS 抓取(分月执行以避免超时)
echo [1/2] 开始 ODS 数据抓取...
python -m etl_billiards.cli.main --pipeline-flow FULL --window-start "%WINDOW_START%" --window-end "%WINDOW_END%" --window-split-unit month --force-window-override
if %ERRORLEVEL% NEQ 0 (
echo [错误] ODS 抓取失败!
pause
exit /b 1
)
echo.
echo [2/2] 开始 DWD 装载...
python -m etl_billiards.cli.main --pipeline-flow INGEST_ONLY --tasks DWD_LOAD_FROM_ODS --window-start "%WINDOW_START%" --window-end "%WINDOW_END%" --force-window-override
if %ERRORLEVEL% NEQ 0 (
echo [错误] DWD 装载失败!
pause
exit /b 1
)
echo.
echo ====================================
echo 数据补全完成!
echo 结束时间:%date% %time%
echo ====================================
pause