Do you guys have any experience in designing the database of the website message center? There are all messages unread messages read messages one-click ignore function.

* * the current idea is two tables

  1. platform message table-send messages to all users
  2. user Reading record Table has a field msg_ids records all the id users who read the message read a message, splicing the message id to the end of the msg_ids

read message: take out all msg_ids id, search platform message table
unread message: Filter msg_ids all id, take the rest
feel this is a bit hasty, what do the bosses think? * *

Apr.09,2021

Why not use a table to handle user_id (user id), msg (messages). (other fields), is_read (read or not).
all messages: user_id=XXX
unread: user_id=XXX and is_read = 0
read: user_id=XXX and is_read = 1
ignore: update is_read = 1 where user_id=XXX and is_read = 0


change your train of thought and send it to all users with one announcement.
this facilitates unified message processing.

Menu