I have a table with an enum column with only integers. How could I store the meaning of each integer? I will never use them as direct query parameters.
- New table ?
- A "COMMENT ON TABLE "?
- What else?
#PostgreSQL
-
-
Replying to @Benoit_Tgt
Don’t use enums. /s AR 5 has a much better handling of enums as text rather than ints IIRC. Immutable function or lookup table is totally cool.
1 reply 0 retweets 1 like -
Replying to @mashd
But we are little bit scared about this answer from
@sgrif (https://github.com/rails/rails/commit/67c1719012506c3387df067961252b5df50a97ce#r18921263 …)pic.twitter.com/np1CndQvO0
2 replies 0 retweets 0 likes
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.