A postal code looks numeric until an integration drops its leading zero or encounters a code with letters. Store the value as text and validate it against the country associated with the address.
Keep formatting rules at the boundary where you know the destination requires a particular representation. Use example addresses with leading zeros, optional spaces, and a missing code when testing an import. A country-specific check works better than applying one fixed length to every address.
Leave a Reply