Answer the question
In order to leave comments, you need to log in
What is the best way to avoid repeating ENUM in the database?
There are 2 boards. They have a field that is responsible for the order status, with a data type like
ENUM('BOOKED', 'SUBMITTED', 'PAID', 'CANCELLED', 'NOT_ACTIVE', 'REFUSE').
what if I have 10 such plates? and I want to change ENUM? How to make it more flexible and put it somewhere in one place? Thanks
Answer the question
In order to leave comments, you need to log in
To do this, all of a sudden, you can use a value table and foreign keys.
Although, of course, creating tables when working with a database may seem like a radical idea to someone.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question