You are here:
Validate Loyalty Ledger Traceability Records
Use the Validate Loyalty Traceability Ledgers Data Processing Engine template. It validates the Loyalty Ledger Traceability records for each active, fixed-duration, and redeemable currencies in the loyalty program. It calculates member balances and checks for redeemed expired points, mismatched debit and credit points, and overconsumed points.
Required Editions
| Available in: Lightning Experience |
| Available in: Enterprise, Performance, Unlimited, and Developer Editions with Loyalty Management |
For each loyalty program containing imported data, perform these steps.
- Create a Data Processing Engine definition by using the Validate Loyalty Traceability Ledgers template.
- Enter a value for the Loyalty Program Name input variable.
- Run the Data Processing Engine definition.
- Review the datasets by using the Data Assets tab in Data Manager.
- If there are any errors listed in the dataset, adjust your records to fix the errors. Then, rerun the definition to confirm data validity.
For each member currency with errors, the dataset contains an error record with fields that show error messages for these issues.
- Debit ledgers are consuming points from expired credit ledgers.
- The sum of the points consumed from a credit ledger based on the trace records exceeds the points in the credit ledger.
- The sum of points consumed by a debit ledger based on the trace records doesn't match the points in the debit ledger.
- The calculated point balance from traces doesn't match the current member currency point balance.
Example of Loyalty Ledger Traceability Record Validation
Here's an example of how the Data Processing Engine definition identifies inconsistencies by comparing loyalty ledgers and traceability loyalty ledgers.
Loyalty Ledgers
Here are the loyalty ledgers for a loyalty program member, Adria Darby, whose points balance is 17.
| Ledger ID | Event Type | Activity Date | Expiry Date | Points |
|---|---|---|---|---|
| CL1 | Credit | 1/1/2024 | 1/1/2025 | 10 |
| E1 | Expiry | 1/1/2025 | — | 10 |
| CL2 | Credit | 1/1/2025 | 1/1/2026 | 15 |
| CL3 | Credit | 1/3/2025 | 1/3/2026 | 10 |
| CL4 | Credit | 1/3/2025 | 1/3/2026 | 10 |
| CL5 | Credit | 1/4/2025 | 1/4/2025 | 30 |
| DL1 | Debit | 1/3/2025 | — | 10 |
| DL2 | Debit | 1/6/2025 | — | 10 |
| DL3 | Debit | 1/6/2025 | — | 10 |
| DL4 | Debit | 1/8/2025 | — | 18 |
Traceability Loyalty Ledgers
Here are the traceability loyalty ledgers for Adria Darby.
| ID | Credit Ledger ID | Debit Ledger ID | Points | Event Type |
|---|---|---|---|---|
| TL1 | CL1 | DL1 | 10 | Debit |
| TL2 | CL2 | DL2 | 10 | Debit |
| TL3 | CL2 | DL3 | 10 | Debit |
| TL4 | CL3 | DL4 | 10 | Debit |
| TL5 | CL4 | DL4 | 10 | Debit |
Validation Errors
After the Data Processing Engine job validates the records, it creates a record with the errors. Here's the list of errors and the reasons.
| Error | Reason |
|---|---|
| Debit ledgers are consuming points from expired credit ledgers. | The TL1 traceability loyalty ledger is invalid because it maps the DL1 debit ledger, created on 1/3/2025, to the CL1 credit ledger that expired on 1/1/2025. |
| The sum of the points consumed from a credit ledger based on the trace records exceeds the points in the credit ledger. | The TL2 and TL3 traceability loyalty ledgers are tracing 20 points to the CL2 credit ledger though the CL2 loyalty ledger has only 15 points. |
| The sum of points consumed by a debit ledger based on the trace records doesn't match the points in the debit ledger. | The TL4 and TL5 traceability loyalty ledgers are tracing 20 points to the DL4 debit ledgers though the DL4 debit ledger has a debit of only 18 points. |
| The calculated point balance from traces doesn't match the current member currency point balance. | The calculated point balance is 15 and it doesn’t match the member’s actual balance of 17. Calculation details:
|

