Hi, sorry if this question has been asked before, I searched but wasn't sure on the proper name for what I'm looking for.
I'm pretty much a newcomer to rails and development in general, I've done some hacky programming but I wouldn't say I know what I'm doing. I've always been at a loss on how to define "types" in my Rails models and in databases in general.
For example, say I have a model "Car" and it has the property "Colour", where Colour is chosen from a known set rather than an RGB value or whatever. Something tells me that there should be another table (and associated model) for Colour and then have some kind of relationship between the two, but which relationship is appropriate? A car doesn't BELONG to its colour, or vice versa.
Or of course I could just store an integer and look it up in code, but this feels wrong to me.
What did I miss? :)