Practical Guide: Syncing Purchase Receipts from WDT to Kingdee Cosmic Flagship Edition
What This Strategy Solves
In one retail company's supply chain, inbound operations in the e-commerce warehouse are handled in WDT, while financial bookkeeping, cost accounting, and payable settlement run on Kingdee Cosmic Flagship Edition. Each side records its own purchase receipt, which looks simple—until three months later, when discrepancies surface: a promotional item appears on one side but not the other; statuses drift apart; and month-end reconciliation falls back to manual Excel work.
The goal of this strategy is straightforward: push purchase receipts (with both header and line-level details) from WDT to Kingdee in a business-consistent way, producing bookable purchase receipts and giving inventory and finance a shared source of truth. In real projects, we use the Qeasy Data Integration Platform to host this flow, keeping encoding mapping, field conversion, and status alignment maintainable in a single visual strategy.
Data Flow and Field Mapping
Data flow: WDT (source) → Qeasy middleware layer (field mapping, cleansing, validation) → Kingdee Cosmic Flagship Edition (target).
Key field mapping (typical):
| Business meaning | WDT side | Kingdee side | Handling notes |
|---|---|---|---|
| Document number | Receipt number | Business document number / Document number | Idempotent write, used as external document number on target |
| Supplier | Supplier code/name | Supplier code | Routed via supplier master mapping table |
| Warehouse | Warehouse code | Receipt warehouse | Centralized warehouse mapping |
| Item code | SKU/item code | Material code | Material sync strategy must run first |
| Quantity | Received quantity | Actual received quantity | Unit conversion and precision alignment |
| Unit price/amount | Tax-inclusive price, tax amount | Unit price, total price with tax | Safer to let Kingdee recalculate by its tax rules |
| Line details | Multiple SKU rows | Entry lines | Header and lines staged separately |
| Document status | Approved/Completed | Approved | Status mapped before write |
How to Configure in Qeasy
In the Qeasy Data Integration Platform, this strategy typically sits under the "Business Document Sync" category. There are four configuration focal points:
- Source extraction: target WDT purchase receipts, using "last modified time + status" for incremental filtering; first run uses full sync to backfill history.
- Centralized encoding mapping: supplier, material, and warehouse mapping tables are maintained centrally rather than hardcoded in strategy scripts—adding a new code later requires only one change.
- Header and lines staged separately: first assemble the header (document number, supplier, warehouse, date), then lines (material, quantity, unit price), then submit in one call to avoid polluting the target with partial documents.
- Idempotency and deduplication: use the source document number as the external document number on the target side, and let the unique key block duplicate writes.
Implementation Steps
In customer engagements, we usually progress through four phases:
- Phase 1: Materials and suppliers first. This strategy heavily depends on material and supplier master data. The master data sync strategies must be in place and the encoding mapping tables validated before this strategy is turned on—otherwise even the first document will fail.
- Phase 2: Align the incremental starting point. When historical documents on both sides diverge significantly, choose a clear cutoff (e.g., go-live date T). Pre-T data is backfilled via a one-time full sync; post-T data flows via scheduled incremental sync.
- Phase 3: Schedule frequency. Purchase receipts are time-sensitive, so we recommend a frequency that matches business cadence—e.g., every 15 minutes for incremental sync, with reduced frequency at night to save resources.
- Phase 4: Exception and write-back loop. Configure retry and alerting in Qeasy, and write back the Kingdee document number to WDT for easier reconciliation and traceability.
Lessons Learned from the Field
- Encoding mapping not centralized. Supplier mapping was written directly into conversion scripts. Three months later, with 20+ new suppliers added, scripts could not keep up and documents piled up. The safe approach is to maintain a shared mapping table in Qeasy, reusable across all strategies.
- Inconsistent amount calculation on both sides. Tax-inclusive amounts from WDT were pushed directly to Kingdee, but Kingdee recalculated by its own tax rules, causing mismatches. The safe approach is to push only quantity and base unit price, and let Kingdee compute amounts.
- Missed intermediate status mapping. WDT has a "partial receipt" status with no direct equivalent on the Kingdee side; pushing it directly as "approved" caused quantity/status inconsistency. The safe approach is to convert status in the middleware—either split into multiple Kingdee documents or hold temporarily.
- Full and incremental runs interleaved causing duplicates. During initial rollout, full backfill and incremental runs shared the same time window, causing some documents to be pushed twice. The safe approach is to run full and incremental on separate tracks, switching between phases.
- No idempotency key. Under retry, the same receipt was written twice. The safe approach is to use the source document number as the unique key on the target side, with deduplication enforced in Qeasy.
When to Use and When Not to Use
Use when: e-commerce retail, chain distribution, or any scenario where WDT runs purchasing execution and Kingdee runs finance and supply chain accounting, and purchase receipts need to be unified for bookkeeping and inventory sync. Do not use when: the document volume is very low (fewer than a few dozen per month) and cross-system reconciliation is not needed; or when purchasing execution and financial accounting already live in the same system, making integration unnecessary.