SAS Quality Knowledge Base for Contact Information 27

Postal Code (with Country Code)

Standardization Definition

Postal Code (with Country Code)
Description The Postal Code (with Country Code) standardization definition standardizes postal codes and adds a domestic country code, unless there is already a country code in the input.
Examples Input Output
H2N-1Z2 CA-H2N1Z2
h1n2w2 CA-H1N2W2
CDN E8C2R8 CA-E8C2R8
U-27514 US-27514
U.S.A. 27514 US-27514
!V6B 2R7 CA-V6B2R7
Postal Code: S9H 3W4 CA-S9H3W4
Code Postal: S9H 3W4 CA-S9H3W4
V6B C56 CA-V6B5C6
MIC 5G5 CA-M1C5G5
FR. 12345 FR-12345
12345 6789 US-12345-6789
Remarks If a postal code contains 5 digits, followed by a space or hyphen, followed by 4 digits, it is recognized as a United States postal code, and a hyphen is placed between the two sets of digits per U.S. convention.