mysql - Enum in a database -
I have a feature in a table that I want to be able to update. What is the best way to implement it?
- To create a second table with the values and "enum_id" in the second table, and when I want to add or update the en enum value, then just update the specific row Or delete or add?
Using MISL
< p> If the second choice is better then update your property values when you update / insert new feature, Master T Theid of the attribute in Lika remains the same
If you go with the first choice and use the
ENUM data type, you do You will only need to do INSERT or UPDATE on your attribute table.
Alternate Table Every time you need to insert or update your attributes, and you need to enter each
ENUM The value must be
UPDATE in the main table.
Comments
Post a Comment