trending_subreddits table
The trending_subreddits table in the Reddit Clone Database Schema schema has 5 columns, with 1 foreign key to subreddits.
A daily snapshot rather than a live computation, so the trending list is stable for everyone who loads the page on the same day.
Columns (5)
| Column | Type | Constraints | Description |
|---|---|---|---|
| subreddit_id | uuid | not null, references subreddits.id | |
| ranked_on | date | not null | |
| position | smallint | not null | |
| growth_rate | double | not null | |
| source | trending_source | not null |
Indexes (1)
(subreddit_id)
Relationships
trending_subreddits.subreddit_idreferencessubreddits.id