Misaka_Company a227aed0cb feat(sync): add one-shot full sync (TRUNCATE + bulk INSERT)
- New `sync.fullsync` CLI: `python -m sync.fullsync config.yaml [--db F] [--table T] [--clear-change-log]`
- AccessReader: list_user_tables / read_all_rows / read_all_log_ids
- SqlWriter: table_exists / truncate_target (TRUNCATE w/ DELETE fallback) / bulk_insert (SET IDENTITY_INSERT + chunked fast_executemany)
- Reuses FileMapping exclude/include rules (exclude beats include, same as capture)
- Preserves Access IDs via IDENTITY_INSERT; target schemas have no FKs so TRUNCATE is safe
- TableChangeLog NOT cleared by default (opt-in --clear-change-log)
- tests/test_fullsync.py covers resolve_tables exclude/include precedence
2026-07-14 18:06:39 +08:00

ProductionDataBaseSync_DataMacro

Access → SQL Server 增量同步(数据宏驱动)。详见 docs/superpowers/specs/2026-07-14-access-datamacro-sync-design.md

运行

.venv/Scripts/python.exe -m sync.service

配置

编辑 config.yaml(从 config.example.yaml 复制并填入真实凭据)。

Description
Access to SQL Server incremental sync, data-macro driven
Readme 209 KiB
Languages
Python 83.8%
TSQL 16.1%
Batchfile 0.1%