Using the following as an example I am trying to figure out the best way set up a MySql database.
FoodGroupTypeCode
: Grain, Vegetable, Fruit, Dairy, Protein
What is the best Data Type to use to represent this attribute?
CHAR(1)
: G, V, F, D, PTINYINT
: Using number codes (i.e. Grain = 1, Vege = 2)ENUM
VARCHAR(9)
: Using full names- Other (explain)
Option 4 is really not a consideration of mine, unless someone can really validate it. I have read a lot of "opinions" on the subject but looking for more concrete reasons for picking one over the other. I appreciate any input that someone can give to that degree rather then something such as "I like ENUM because it is fast."