Quantcast
Channel: database relations - Stack Overflow
Browsing all 7 articles
Browse latest View live

Answer by loginx for database relations

This related to the subject of Database Normalization. What you want is set up a schema that looks like this: Table 'activities': (id, name)Table 'emotions': (id, name)Table 'activity2emotion:...

View Article



Answer by Pierre for database relations

don't create a new table. I would use 3 tables:one for the activtiesone for the emotionsand a table activity_to_relation (many to many association )

View Article

Answer by Aaron for database relations

It is generally not a good idea to create a new table for each of a set of entities. Setup your tables like this:Emotions-Id-Name-...other informationActivities-Id-Name-... other...

View Article

Answer by littlegreen for database relations

It would be better to have one table called emotions (id, name), another called activities (id, name) and a third one relating the two. (id_emotion, id_activity).

View Article

Answer by rayd09 for database relations

I wouldn't recommend adding a new table for every emotion. It would probably be better to have an Activity table, an Emotion table, a join table between Activity and Emotion which I'll call...

View Article


Answer by Randy Minder for database relations

I would think you would want a table named Emotions which would contain the universe of emotions. Then you would want a table named Activities which contains the universe of activities.You then need to...

View Article

database relations

Let's say I want to make a database that relates emotions with activities. Would it make sense to make a new table every time i encounter a new emotion and inside that table would by say the ids of all...

View Article
Browsing all 7 articles
Browse latest View live




Latest Images