Say you have the following many-to-many table relation:
user
-----
id
first_name
last_name
user_prefs
----------------
id
preference_name
user2user_prefs
-------------
id
user_id
user_pref_id
But say you have the user preference of "homepage" and need somewhere to store the actual homepage url. Where would that go?
I can't put a value in user_prefs because then the same value would apply to everyone who has that mapping.
I CAN put it in user2user_prefs like so:
user2user_prefs
-------------
id
user_id
user_pref_id
value
But is this the best way in terms of normalization? Something doesn't feel quite right about the way im doing it (for one thing, i can't use an ENUM on the new "value" because it would have to contain all values for all preferences). Any thoughts?
Thanks! Stabby L