texasstarbc

EDI Integration with TrueCommerce

This document describes the Electronic Data Interchange (EDI) integration between Business Central and TrueCommerce for automated electronic document exchange with trading partners.

Overview

The Texas Star Nuts extension integrates with TrueCommerce EDI and eCommerce (v9.0.0.0) to enable:

The primary focus of custom integration is ASN (Advanced Shipping Notice) transmission when warehouse shipments are posted.


TrueCommerce Field Mapping

Overview of TRC Fields

TrueCommerce uses fields prefixed with “TRC” on Business Central tables to capture data for EDI transmission. The Texas Star extension automatically synchronizes data to these fields.

Field Mapping Reference

Business Central Field TRC EDI Field Purpose EDI Segment
Bill of Lading No. TRCBillofLading BOL number HL/TD3
Bill of Lading No. TRCUDF2 BOL backup UDF segment
Seal No. TRCUDF3 Trailer seal number AT7
Trailer Reference TRCTrailerNumber Trailer number AT7
Trailer Reference TRCCarrierPro Carrier PRO/tracking AT7
Shipping Agent Code TRCUDF5 Carrier SCAC code AT7/TD5
- TRCUDF4 ARN (Authorization Return Number) REF
TRCASNType TRCASNType ASN type (Pick & Pack vs Pallet) BSN/HL

Field Synchronization Logic

1. Bill of Lading Number

Source: Warehouse Shipment Header - Bill of Lading No.

Target TRC Fields:

Synchronization Timing:

Code:

WarehouseShipmentHeader.TRCBillofLading := WarehouseShipmentHeader."Bill of Lading No.";
WarehouseShipmentHeader.TRCUDF2 := WarehouseShipmentHeader."Bill of Lading No.";

EDI Usage:

Code Reference: TSNEventSubscriber.Codeunit.al


2. Seal Number

Source: Warehouse Shipment Header - Seal No.

Target TRC Field: TRCUDF3

Synchronization Timing:

Code:

if WarehouseShipmentHeader."Seal No." <> '' then
    WarehouseShipmentHeader.TRCUDF3 := WarehouseShipmentHeader."Seal No.";

EDI Usage:

Business Process:

  1. Warehouse team closes and seals trailer
  2. Seal number recorded in warehouse shipment
  3. Field synced to TRCUDF3
  4. ASN transmitted with seal number
  5. Customer verifies seal upon delivery

Code Reference: TSNWarehouseShipmentHeader.TableExt.al


3. Trailer Reference

Source: Warehouse Shipment Header - Trailer Reference

Target TRC Fields:

Synchronization Timing:

Code:

if WarehouseShipmentHeader."Trailer Reference" <> '' then begin
    WarehouseShipmentHeader.TRCTrailerNumber := WarehouseShipmentHeader."Trailer Reference";
    WarehouseShipmentHeader.TRCCarrierPro := WarehouseShipmentHeader."Trailer Reference";
end;

EDI Usage:

Typical Values:

Code Reference: TSNEventSubscriber.Codeunit.al


4. Shipping Agent Code

Source: Warehouse Shipment Header - Shipping Agent Code

Target TRC Field: TRCUDF5

Synchronization Timing:

Code:

if WarehouseShipmentHeader."Shipping Agent Code" <> '' then
    WarehouseShipmentHeader.TRCUDF5 := WarehouseShipmentHeader."Shipping Agent Code";

EDI Usage:

Common SCAC Codes:

Business Impact:

Code Reference: TSNEventSubscriber.Codeunit.al


5. ASN Type

Source: Sales Header - TRCASNType

Values:

Determination Logic:

if SalesHeader."TSN Total Quantity" > 25 then
    SalesHeader.TRCASNType := SalesHeader.TRCASNType::"Pallet Pick and Pack"
else
    SalesHeader.TRCASNType := SalesHeader.TRCASNType::"Pick and Pack";

Synchronization Timing:

EDI Usage:

Pick and Pack ASN:

Pallet Pick and Pack ASN:

Business Impact:

Code Reference: TSNWarehouseShipmentHeader.TableExt.al


ASN (Advanced Shipping Notice) Workflow

1. Order Processing

2. Warehouse Shipment Creation

3. Pre-Shipment Data Entry

4. Picking Process

5. Shipment Posting

6. ASN Transmission

7. Customer Receipt


ASN Data Elements

Header Level (BSN Segment)

Shipment/Order Level (HL Segment)

Carrier Level (TD3/TD5 Segments)

Item Level (LIN/SN1/PID Segments)

Pallet Level (HL/MAN Segments - Pallet Pick & Pack only)


EDI Setup Requirements

TrueCommerce Configuration

1. Trading Partner Setup

2. Document Mapping

3. Communication Method

4. Testing

Business Central Configuration

1. Warehouse Setup

2. Customer Setup

3. Item Setup


Weight and Volume Tracking

Purpose

ASN transmission includes weight and volume for:

Data Source

Warehouse Shipment Line Fields:

Calculation:

Aggregation: Total weight and volume rolled up to shipment header for ASN transmission.

EDI Usage

Transmitted in TD1 segment of ASN:


Pallet Tracking

Manual Pallets vs. Total Pallets

Manual Pallets:

Total Pallets:

License Plate Integration

Warehouse Insight Integration:

ASN Structure with License Plates:

Shipment (HL01)
  Order (HL02)
    Pallet 1 - SSCC: 00012345678901234567 (HL03)
      Item A - 10 cases (HL04)
      Item B - 5 cases (HL04)
    Pallet 2 - SSCC: 00012345678901234568 (HL03)
      Item C - 20 cases (HL04)

Troubleshooting EDI Issues

Issue: ASN Not Transmitted

Possible Causes:

  1. TRC fields not populated
  2. Customer not set up as EDI trading partner
  3. TrueCommerce integration not active

Solution:

  1. Verify all TRC fields populated before posting:
    • TRCBillofLading
    • TRCUDF2 (BOL)
    • TRCUDF3 (Seal)
    • TRCTrailerNumber (Trailer)
    • TRCUDF5 (Shipping Agent)
  2. Check customer EDI setup in TrueCommerce
  3. Verify TrueCommerce service is running
  4. Review TrueCommerce error logs

Issue: Customer Rejects ASN

Possible Causes:

  1. Field mapping mismatch
  2. Item number not recognized
  3. UOM (Unit of Measure) not accepted
  4. Missing required fields

Solution:

  1. Review customer EDI requirements document
  2. Validate item number format (customer item no. vs. UPC)
  3. Check UOM code matches customer expectations
  4. Ensure all customer-required fields populated
  5. Request ASN rejection reason from customer

Issue: BOL Number Not Syncing

Symptom: TRCBillofLading or TRCUDF2 empty after shipment creation

Cause: Number series not configured or event subscriber not firing

Solution:

  1. Verify BOL number series configured in Warehouse Setup
  2. Check “Bill of Lading No.” populated on warehouse shipment header
  3. Verify TSN Event Subscriber codeunit published
  4. Test event subscriber with debug/log

Issue: Seal Number Not in ASN

Symptom: Customer reports seal number missing from ASN

Cause: Seal No. not entered before posting or TRCUDF3 not syncing

Solution:

  1. Always enter Seal No. before posting shipment
  2. Verify TRCUDF3 populated when Seal No. entered
  3. Check event subscriber: OnBeforeWhseShptHeaderModify
  4. Ensure TrueCommerce maps TRCUDF3 to AT7 segment

Issue: Wrong ASN Type Sent

Symptom: Customer expects pallet-level ASN but receives line-item level

Cause: ASN type determination threshold mismatch

Solution:

  1. Review current threshold (25 units)
  2. Verify “TSN Total Quantity” calculation on sales order
  3. Adjust threshold in code if customer requirements differ
  4. Consider customer-specific ASN type override

Best Practices

1. Pre-Shipment Validation

2. Customer-Specific Requirements

3. Data Quality

4. Error Monitoring

5. Training


Integration Architecture

Business Central
    ↓
    ├─ Warehouse Shipment (with TRC fields)
    ↓
    ├─ Event Subscribers (field sync)
    ↓
    ├─ Post Warehouse Shipment
    ↓
TrueCommerce Extension
    ↓
    ├─ Read TRC fields
    ├─ Build 856 ASN message
    ├─ Apply customer-specific mapping
    ↓
TrueCommerce Network
    ↓
    ├─ Transmit via AS2/VAN
    ↓
Customer EDI System
    ↓
    └─ Receive and process ASN

Summary

The EDI integration with TrueCommerce provides:

  1. Automated ASN Transmission: Electronic advance notice of shipments
  2. Field Synchronization: Automatic mapping of BC data to EDI fields
  3. ASN Type Intelligence: Automatic determination of pick & pack method
  4. Comprehensive Data: BOL, seal, trailer, carrier, lot tracking
  5. Customer Satisfaction: Accurate advance shipment information
  6. Operational Efficiency: Eliminates manual ASN creation
  7. Compliance: Meets trading partner EDI requirements

Key Benefits


See Also: