Other#
Preferred, Approved, and Non-Approved City Names#
The Perfect Address SDK address database includes almost 75,000 city and town names in common use within the delivery areas served by the US Postal Service. However, the USPS has assigned only about 43,000 5-digit ZIP codes. Obviously some of these 75,000 names must apply to the same 5-digit ZIP code. That is, in fact, exactly the case: some towns or portions of a town are known to the local folk by several different names. The USPS, in its great wisdom, has selected one (and only one) city name for each 5-digit ZIP code as the name preferred (by the USPS, at least) for use on the last line of all mail addressed to that 5-digit ZIP code. There may be other names which apply to that same 5-digit ZIP code. Some people object to using the “preferred” name specified by the USPS; these people may instead use some other, locally preferred name. This can be quite confusing, and leads to duplicate records in an address list which are hard to detect. To deal with this problem, we have included in the database many “alias” city names, along with the ZIP codes to which they apply. An alias city name may be “approved” by the USPS or may be “unapproved”. If the name is approved it may be used on the last line of mail even though the name is not the officially preferred name. Unapproved names are not to be used on the last line of mail in any case. Note that in some cases a particular city name may be preferred for some ZIP codes but an alias name (approved or unapproved) for other ZIP codes. This frequently occurs when the exact political boundary between adjacent cities is obscure, leading people to use the two city names interchangeably within the boundary area. Here is an example:
Zip Code |
Preferred City Name |
Alias City Name |
---|---|---|
80014 |
Aurora Denver |
(not approved) |
80220 |
Denver Aurora |
(not approved) |
80215 |
Lakewood Denver |
(approved) |
80202 |
Denver |
(None) |
ZIP codes 80014 and 80220 fall into the boundary area between Denver and Aurora, Colorado. Because the actual political boundary between these two cities is not clearly defined, people often get confused about the correct city name in these two areas. Although Denver is listed in the database as an alias city name for ZIP code 80014, the USPS wants the name Denver to be changed to Aurora. Denver is “unapproved” for use on the last line for mail addressed to ZIP code 80014. However, for mail addressed to 80215, for which Lakewood is the “preferred” name, Denver is an “approved” alias, which CAN be used on the last line. And, of course, for ZIP code 80202, Denver is the preferred city name. For this ZIP code there is no alias city name. Denver, then, is an example of a city name which is preferred (80202), approved (80215), and unapproved (80014). The general rule applied by the DLL in these cases is this: first attempt to establish a match between the city name (preferred or alias) and the ZIP code. If the city name is preferred or approved for that ZIP code, retain the original city name. If the city name is not approved for that ZIP code, change the city name to the preferred city name. However, the DLL searches BOTH cities for an address match, and relies on both ZIP code and city information contained in the address records to finally decide which city name (and ZIP code) to place on the last line. Of course, all bets are off if the ZIP code or city name is missing from the input address. The DLL can function with only a ZIP code or only a city-state, but must resort to other, slower search methods to validate such an address.
Address Matching Rules#
The DLL follows US Postal Service address matching rules to find a correct address match. The fundamental rule is called the “one component failure rule”. In simple terms, this rule permits an address match if and only if no more than a single delivery address component mismatch exists, where a “component” is defined as a predirectional, street name, street suffix, or a post-directional.
This address:
250 E CENTER ST N
has all four address components. If one component can be added, changed, or deleted to achieve a unique match, the DLL is allowed to correct the address and return the ZIP+4. Under USPS rules, if more than one component is incorrect, no match is allowed. If adding, changing or deleting a single component results in multiple matches, no match can be returned. The algorithm calls for adding a suffix first, before adding a directional. If there is no match, change or delete the suffix. Finally, change or delete a directional. Swapped directionals are NOT considered to be a component failure. If there is no exact address match within the normal city, the DLL applies the “one component failure rule” within the input ZIP code. If there is still no match, the DLL applies the “one component failure rule” to all addresses within the postal finance number. If there is still no match, the address is rejected. The DLL uses an advanced phonetic matching algorithm to match city and street names. It also uses tables of common abbreviations to enhance matching of city and street names.
Multiple Address Matches#
In applying the “one component failure rule” the DLL often finds multiple addresses which satisfy the address matching criteria. However, the USPS address matching rules prohibit the DLL from making a “guess” as to which address is correct.
For example, given this address:
250 FOREST
and applying the “one component failure rule”, the DLL might find these potential matches:
250 FOREST AVE
and
250 FOREST DR
Either address could be correct, and the DLL has no way to resolve the conflict. USPS rules call for the address to be rejected. In general, any time the DLL applies the “one component failure rule” and finds multiple potential matches, the input address is rejected. In this case the DLL returns the error code XC_MULT (multiple matching records).
To help you resolve address conflicts such as the example above, the DLL provides two functions which permit your program to examine the matching records and take some appropriate action. 6 - 10 Development Environment UNZ_GETMATCHCOUNT returns an integer count of the number of matching addresses found by the DLL on the previous UNZ_CHECKADDRESS call. This function can be used onlywhen the return code from UNZ_CHECKADDRESS is XC_MULT (multiple matching records).
UNZ_GETMATCHADDR returns one selected address from the group of matching addresses. You must specify the address by number, in the range of 1 to n, where n is the number of matching addresses returned by UNZ_GETMATCHCOUNT
Private Mailboxes#
Private Mailbox, PMB, is a new USPS designation for mail sent to a mailbox at a Commercial Mail Receiving Agency (CMRA), such as Mailboxes Etc. The PMB designation must be used in place of other secondary address types, such as BOX, STE or APT. The USPS now rejects mail sent to a CMRA with BOX, STE, or APT as the secondary address type. The PMB number can also be placed on the line above the street address line. Acceptable address formats are these:
or
Product Support#
If you have problems with or questions about this product, please contact Melissa technical support via email at:
tech@melissa.com