Qeasy Cloud
Get Started

U8 Material Outbound Red-Stock Sync to PRO Other Inbound: A Single-Strategy Tutorial

· 系统管理员· Integration Solutions· 22 views· 3 min read
WDT用友U8用友U8Inventory Sync红字单据轻易云Supply Chain

What This Strategy Solves

A retail or manufacturing enterprise runs U8 as the financial inventory ledger and Wangdiantong (Wangdian Tong) as the store-fulfillment system. When red-stock outbound documents (generated by returns, adjustments, scrapping, etc.) reverse inventory in U8 but the fulfillment side never sees them, stores end up "with stock on paper, nothing in the warehouse." This strategy is dedicated to syncing all types of U8 red-stock material outbound documents into Wangdiantong PRO Other Inbound, aligning inventory semantics on both sides.

Data Flow and Field Mapping

Data flow: Yonyou U8 (material outbound document – red-stock, all types) → Qeasy Data Integration Platform → Wangdiantong PRO Other Inbound.

Key field mapping (empirical values; refer to actual metadata on both sides):

DimensionU8 Field (Source)Wangdiantong PRO Field (Target)Handling Notes
Document No.ccode / document numberexternal_noPass through verbatim for traceability
Document Typebusiness type (red flag)inbound_type = Other InboundIdentified via sign / red flag
Warehousecwhcodewarehouse_noCentralized warehouse code mapping
SKU Codecinvcodesku_idCentralized product code mapping
Quantityiquantity (negative)qty (absolute value)Convert negatives to positives before writing
Unitcinvm_unitunitOne-to-one mapping
Batchcbatchbatch_noRequired when batch management is enabled
Business Dateddatecreated_atPreserve source business date

How to Configure It on Qeasy

  1. Source connector: select the U8 adapter and configure the account set (desensitized, not expanded in this article).
  2. Target connector: select the Wangdiantong · Enterprise Qimen / PRO adapter and configure store and authorization.
  3. Data extraction: use the RdRecord11 red-stock outbound view, filter by ddate and ccode, with pagination support.
  4. Transformer: write a field-mapping script that focuses on two things—taking the absolute value of red-stock quantity, and mapping the document type to "Other Inbound".
  5. Centralized code mapping: maintain warehouse, product, unit, and batch mappings in a single Qeasy mapping table, so later adjustments don't require code changes.
  6. Write strategy: write each document into PRO individually, failures go to a retry queue; the idempotency key is recommended as external_no + sku_id + batch_no.
  7. Scheduling: incremental polling every 5–15 minutes, with a one-time full backfill on first run.

Implementation Steps

  1. Phase 1 – Confirm the incremental starting point: take the timestamp of the most recent U8 red-stock outbound document as the incremental anchor and persist it into the cursor table on Qeasy, then advance by ddate + document number.
  2. Phase 2 – Trigger full backfill: during the first go-live or historical reconciliation, set up a one-time full backfill task to push the past N months of red-stock documents into PRO, and switch the target system into "import mode" during this window to avoid triggering downstream jobs.
  3. Phase 3 – Scheduling frequency: in steady state, 5–15 minute incremental polling is recommended; tighten to 5 minutes during peak hours, and run one full reconciliation at night during off-peak.
  4. Phase 4 – Reconciliation loop: run a daily red-stock reconciliation report in the early morning, comparing U8 reversal quantities against PRO inbound quantities; mismatches enter a manual review queue.

Lessons Learned from the Field

  1. Forgetting to take absolute value of red-stock quantity. Classic pitfall: pushing negative quantities directly to PRO—PRO either rejects the inbound validation or reverses inventory in the wrong direction. The safe approach is to enforce Math.abs() in the transformer.
  2. Mixing document types. U8 keeps both blue-stock and red-stock records in the same table; without filtering by document type, data flows in the wrong direction. The recommended approach is to filter red-stock records at the extraction SQL stage, rather than deciding downstream.
  3. Scattered code mappings. When warehouse/product code mappings are written into scripts, adding a new warehouse later means editing many places—easily missed. Centralized mapping tables are a common pattern among Qeasy customers, and the maintenance cost drops dramatically.
  4. Coarse-grained idempotency keys. Using only the document number as the idempotency key causes partial line failures to skip the entire document during retry, leading to missing details. The recommended granularity is the combination external_no + sku_id + batch_no.
  5. Missing batch and expiry data. If U8 has batch management enabled but the sync omits batch_no, PRO-side inventory ends up in a "no-batch" bin, and subsequent outbound cannot match.

When This Applies — and When It Doesn't

Applies: enterprises running U8 and Wangdiantong in parallel, where U8 is the financial inventory master and stores rely on PRO for fulfillment; scenarios where returns, scrapping, and adjustments generate red-stock outbound documents that need to be reflected back as inbound in PRO.

Does not apply: pure back-office financial scenarios that don't participate in fulfillment; U8 versions that don't distinguish red-stock in the document type itself; cases where PRO has retired the "Other Inbound" business type.

Original content. Please credit the source when reposting: https://www.qeasy.cloud/insights/solutions/strat-wdt-u8-8272-111-u8-pro-87e99eb3

Comments