sorting zip codes

  • Thread starter Thread starter Pier Luigi
  • Start date Start date
P

Pier Luigi

hi,
in this reporti can't sort correctly the zip code, and sometime i can't
find
them when i search them with a function vlookup. wHY?
Pier

PROV ZIP CODE
TO 10052
TO 10056
TO 10060
AO 11021
VA 21013
VA 21013
BG 24030
BG 24063
VB 28900
VB 28900
VB 28900
VB 28900
VB 28900
VB 28900
VB 28900
VB 28900
UD 33013
TS 34123
BO 40050
AR 52010
AR 52040
NA 80056
BO 40024
BO 40024
BO 40024
BO 40025
BO 40025
BO 40026
BO 40026
BO 40026
BO 40026
BO 40027
BO 40027
BO 40030

RM 00100
 
and you would have to format them as 00000
so that numbers like 6300 would be 06300.

US zip codes from Italy, how interesting.

I would suggest formatting them as text and have a
FixUSzip5 macro to help with that.
http://www.mvps.org/dmcritchie/excel/join.htm#fixuszip5

Then you can include numbers like 06300-1222
mixed in with 06300 and they will sort correctly. Of course
this would not work have 5 digit and 9 digit codes if the purpose
is to use VLOOKUP. But using a text format would allow you
to use zip codes (or whatever other call them) from any part
of the world in the same column. Outside the US mostly familiar with
Canadian codes, and the system in England is really interesting,
all the more reason to use text.
 
Back
Top