db: add user_actions view.
Add a user_actions view. This view unions together a bunch of tables to produce an event log of every action taken by a user. Also add a bunch of indexes to make queries on this table efficient. Even though the view is an enormous query combining together about 30 different tables, queries are very efficient as long as every table has `created_at` and `(user_id, created)` indexes.
This commit is contained in:
725
db/structure.sql
725
db/structure.sql
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user