Shample Intel
Menu
Catalog quality guide

A twelve-digit padded value can still be invalid

Reproduce checksum failures for 078912345671 and 004123456789 without changing their final digits or presenting them as repaired UPCs.

IdentifiersUpdated Guide slug: invalid-padded-upc-check-digits

The issue to look for

A plausible-looking identifier can have the right width and still fail its check digit. Formatting a number with zeros does not correct an inconsistent original value.

What this check can tell you

This page preserves the two supplied counterexamples as failures and independently documents expected check digits 0 and 2, rather than publishing them as success examples.

A transparent review

  1. Take all digits except the final check digit.
  2. Starting at the rightmost body digit, multiply alternately by three and one, then add the results.
  3. Calculate the amount needed to reach the next multiple of ten.
  4. Compare with the supplied final digit and flag a disagreement for original-source review.

How to read the result

  • For 078912345671 the body requires 0, not the supplied 1. For 004123456789 the body requires 2, not 9. The fixture leaves both strings unchanged and reports two invalid identifiers.
  • The calculation identifies a disagreement, not the position of a typo. Changing a check digit could conceal an error elsewhere in the body. A source-confirmed correction is different from inventing a valid number.

Limits to keep in view

  • Check digits detect many transcription errors but not every error.
  • A passing checksum does not prove a licensed GS1 identifier or a correct product match.
  • The application never replaces a check digit to force validity.
Illustrative sample

Synthetic fixture: synthetic-bad-checksums.csv

This small synthetic example makes the transformation and observation visible. It is an educational illustration, not a claim that a supplier file or external registry was verified.

Fixture ID
bad-checksums
Published fixture reference
bad-checksums
Filename
synthetic-bad-checksums.csv
Encoding
UTF-8
Options
{"repairUpcs":true,"removeZeroStock":false,"removeZeroCost":false}

Input

UPC,SKU
078912345671,BAD-1
004123456789,BAD-2

Output

{
  "checks": {
    "invalidIdentifiers": 2,
    "repairCount": 0
  },
  "cleanedRows": [
    {
      "UPC": "078912345671",
      "SKU": "BAD-1"
    },
    {
      "UPC": "004123456789",
      "SKU": "BAD-2"
    }
  ]
}

Observation: Both supplied padded examples remain invalid and unchanged. Their expected check digits are 0 and 2 respectively; this is diagnostic, not permission to replace digits.

Download synthetic fixture

Sources