Results 1 to 7 of 7
Thread: related words
Jan 6, 2011, 15:32 #1
- Join Date
- Apr 2003
- daejeon, South Korea
- 1 Post(s)
- 0 Thread(s)
Although there are hundreds of thousands of words out there, I pick only 6 words like the below for simplification.
diamond drink gold jewel poor wine
If a user submits a word "drink", it shows wine.
If a user submits a word "gold", it shows jewel and diamond.
If a user submits a word "jewel", it shows diamond and gold.
If a user submits a word "poor", it shows nothing.
If a user submits a word "wine", it shows drink.
I am thinking of two ways.
The 1st way has two tables like the below.
data in wordTable (id) word (1) diamond (2) drink (3) gold (4) jewel (5) poor (6) wine data in relateTable (word1) word2 (1) 3 (1) 4 (2) 6 (3) 4
data in relateTable (word1) word2 diamond gold diamond jewel drink wine gold jewel
that the 1st way will give smaller burden to DB as the data will grow more and more
that the 2nd way will give smaller burden to me because it is more semantic.
(Question1) Which way will be better?
(Question2) Am I on the right track for the purpose?
Do you have another suggestion?
Do you know any web pages relating on this issue?