Ask a database table design question-php Tutorial

Source: Internet
Author: User
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.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.