hi all, it's me again, hehehe :).  well, i've come across many moments where 
i wonder whether i should use an ID, or the actual information.  here's an 
example.  I have two tables, one called STATELIST, and one called Friends.  
The statelist table contains the state abbreviations along with an autoid.  
The friends table just contain a name field, and (this is where i dunno what 
to do) a state_id field.

in the front end, a friend enters his name, and selects the states he lives 
in from a droplist (populated from the statlist table).  What I am wondering 
is, should i use the state's id, instead of actual text?  when do i use it, 
and when dont i use it?  my initial reason of using an id was that it would 
search faster since it is an integer and not regular text.  but i do come 
across times like these and dont know whether to use text or id. i mean what 
if one state secedes?? i will have to delete the state from the table, and 
the state ids that my friend have would have no state to reference to.  But, 
if i use text instead, the information is still there.
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Structure your ColdFusion code with Fusebox. Get the official book at 
http://www.fusionauthority.com/bkinfo.cfm

Archives: http://www.mail-archive.com/[email protected]/
Unsubscribe: http://www.houseoffusion.com/index.cfm?sidebar=lists

Reply via email to