Re: Enums again

Поиск
Список
Период
Сортировка
От Christopher Kings-Lynne
Тема Re: Enums again
Дата
Msg-id 43705F6C.80508@familyhealth.com.au
обсуждение исходный текст
Ответ на Re: Enums again  ("Kaare Rasmussen" <kar@kakidata.dk>)
Список pgsql-hackers
> So, instead of using enums for order states or originating system, I'll 
> user numbers or text? Or implement lookup tables ?

Use a text field and a CHECK constraint if you have just a couple of 
states, and a lookup table if you have many.

Always use a lookup table if you plan on adding new states regularly.

Chris



В списке pgsql-hackers по дате отправления:

Предыдущее
От: "Kaare Rasmussen"
Дата:
Сообщение: Re: Enums again
Следующее
От: Lars Kanis
Дата:
Сообщение: Re: Problems with index-scan on regexp in 8.1