Current location: Hot Scripts Forums » Programming Languages » PHP » States and Countries


States and Countries

Reply
  #1 (permalink)  
Old 06-02-04, 10:48 AM
ExtremeGuy ExtremeGuy is offline
Newbie Coder
 
Join Date: Jun 2004
Location: NH
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
States and Countries

I would like to know your opinion:

I have been using PHP and MySQL for a handfull of years now and have created many databases. I am a little confused over which

way to save country and state information in tables. I have done it a few different ways and was wondering if there is an

unwritten standard that works better than another.

Here are the ways that I have done it in the past with US states:
1) The full state's name (ie. New Hampshire)
2) The state's abbreviation (ie. NH)
3) An id # for the state which is defined in an include file (ie. 28)

So, do most people use one of these methods, and if so which one?

Thanks!
Reply With Quote
  #2 (permalink)  
Old 06-02-04, 08:52 PM
Eclipse's Avatar
Eclipse Eclipse is offline
Coding Addict
 
Join Date: May 2004
Location: Long Island, New York
Posts: 356
Thanks: 0
Thanked 0 Times in 0 Posts
i'd say way 2 is the best or just use postal codes
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump


All times are GMT -5. The time now is 10:37 AM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.