I'm kinda new here, today I got a test in which I had to organize a database respecting the 3 normal forms. Here is a type of E/R diagram: 1
I don't know how to normalize the complaints part, because the text says that a complaint has to contain the email of how registered it and the date, and it can refer to a shop, or to a service center. In that case, it needs the service center id and the model id.
I thought that i could make a table Complaints that had 3 foreing keys: the id of the shop, the id of the service center and the id of the model. Doing so, I would set to null the shopID if the complaint is reguarding the service center and the model, and otherwise set the service center ID and the model ID to null if it is reguarding the shop.
Let me know if you have an idea to solve that. Thank you very much.