Let's assume that I have mytable in mySQL
CREATE TABLE `mytable` (
`gender` enum('MALE','FEMALE','UNISEX') NOT NULL,
);
I don't want to enumerate these values at design time. I want to put them in another_table as values.
In another_table the SELECT values are:
ID NAME
== ======
01 MALE
02 FEMALE
03 UNISEX
I can define the mytable.gender as INT and combine these two tables in WHERE clause with sth like mytable.gender=another_table.id.
Can I create a database level foreign-key relationship with these enum values at design time?