I have an application in which I store PostId
and keywords (Keyword
) belonging to a Post in a table named KeywordsForPost
. The primary key for that table is the combination of PostId
and Keyword
. PostId
is not unique nor is Keyword
.
I needed this implementation because I might need to search for posts regarding the keywords they contain.
I have another table named NewKeywords
. The one and only column in that table is Keyword
. When a post is created, keywords in that post are inserted into both KeywordsForPost
and NewKeywords
tables. An operation is applied to the keywords in the table NewKeywords
at the user's command so that they no longer become "New keywords". So I delete those keywords after that operation is applied. Currently my NewKeywords
table does not have a relationship with any other table. Is this practice justified? Or is there a better practice?
I searched and found this answer.
can we have a table without any relation with the other tables
But did not find it satisfactory.
I also find it different to the question previously asked because it asks a general question, whereas mine is specific. I need to know if a relationship can be added to the table. So far I came up with nothing.