US and Canada Area Codes and States

Rails

So I compiled a list of the area codes in US and Canada and their appropriate mappings to states. I have to do this because my Rails program must geocode based on a caller’s information: first it tries zip code, if that’s not present, then state, and finally it looks up the area code of the caller and maps the state and then sends the state to google for geocoding.

So I compiled the list into a nice CSV file (so you can load into your db with FasterCSV) from http://www.bennetyee.org/ucsd-pages/area.html

You can download my CSV file here.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s