Ask a database table design question to create a database table with report data. it involves three aspects. one is reporting the upload of attachments, report the topic posts of the Forum module, and report the reply to the forum. The purpose is to query the report information. if the attachment is displayed, the "xxx" attachment is reported, the "xxx" post is reported. If you reply to the post, the "xx" reply in the "xx" post is reported. In this case, are tables created separately or in a table. If you save an attachment id, you can get the relevant information. If you reply to a topic, you must obtain the title of the topic. If you reply to the topic, you can only obtain the content of the reply, you also need to know the title of the reply topic. In addition, you must consider displaying the reported information after the reported information or post is deleted. For example, if the id is simply stored, the information corresponding to the id is deleted, and the report information List page cannot be used to obtain the relevant information... Please advise. it may be a bit messy.
Reply to discussion (solution)
A table is enough.
A table is enough.
Do I need a field to store the title and reply content of the topic? If the original post is deleted, the content cannot be obtained. If there is another table, isn't some fields null? is that good?
These fields are similar.
Reporter
Report time
Report Content
Handling status
Appendix
These fields are similar.
Reporter
Report time
Report Content
Handling status
Appendix
On the report list page, I want to display this form. Is it true that when someone replies "xxx" in the "xx" post and is reported, it is stored in the database, store the content in the report content field and then directly call it when it is displayed? I also want to add links to related posts or attachments. you can click here to view them.