Chat
Tables (3)
Users
- id — int — Primary key — NOT NULL
- userName — varchar(255) — Primary key — NOT NULL
- password — varchar(255)
- createdAt — Date
chatroom (Chatrooms)
- id — int — Primary key — NOT NULL
- ownedBy — int — Foreign key → Users.id — NOT NULL
- ownedBy2 — int — Foreign key → Users.id — NOT NULL
message (Messages)
- id — int — Primary key — NOT NULL
- chatroomId — int — Foreign key → chatroom.id — NOT NULL
- from — int — Foreign key → Users.id — NOT NULL
- message — Text