Jump to content
Claris Engage 2025 - March 25-26 Austin Texas ×

Managing zip code


This topic is 8202 days old. Please don't post here. Open a new topic instead.

Recommended Posts

I have to ship items in the USA using UPS. This carrier has defined the country in several zones (2-8). They have a freight chart that indicates rates for each zone. Each zone holds different zip codes.

An example: Zip code starting with 004-005 = zone 8, 010-089 = 8, 474-479 = zone 7, etc.

When I enter a Zip code in the Zip field, I want to get the zone automatically. I don't want to waste my time searching for the right zone. Right now, I am able to extract the first 3 digits of the zip code with this calculation:

LeftWords (Zip Code,3)

I need to create a second field using Case(Zip code = "004"......). As you can see in the example, some zip codes are binded (004 and 005) and other hold several codes (474 to 479). I don't want to defined each code, it will be too long and there won't have enough room (the 255 character limit).

This is the place where I screwed it up.

Any help would be appreciated

Bikeman17

Link to comment
Share on other sites

Hi, create a second database with zip code (the first three letters) and then the zone field.

Each three letter zip code and its zone is a seperate record.

Now, in your main database, create a field with your calc Left(ZipCode,3)

Create a relationship from the calc to the new database zip code.

Now create a new field called zone.

Set tthis new zone field to lookup the zone in the new database based on this relationship.HTH

Link to comment
Share on other sites

This topic is 8202 days old. Please don't post here. Open a new topic instead.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.