user_blocks table

The user_blocks table in the Reddit Clone Database Schema schema has 3 columns, with 2 foreign keys to users.

A block hides content in both directions at read time. It is deliberately NOT a mute and NOT a ban: it is personal, reversible, and never removes anything from the database.

Columns (3)

Columns of the user_blocks table
ColumnTypeConstraintsDescription
blocker_iduuidnot null, references users.id
blocked_iduuidnot null, references users.id
created_attimestamptznot null

Indexes (1)

  • (blocked_id)

Relationships

  • user_blocks.blocker_id references users.id
  • user_blocks.blocked_id references users.id