Added state_group_events count example

master
Alexey Murz Korepov 2019-08-19 17:01:29 +03:00
parent ecac2f63e2
commit 91416a0f3e
1 changed files with 7 additions and 0 deletions

@ -15,6 +15,13 @@ SELECT r.name, s.room_id, s.state_events
ORDER BY ts DESC, state_events DESC
LIMIT 20;
```
and by state_group_events count _(join removed for performance reasons)_:
```
SELECT s.room_id, count(s.room_id) FROM state_groups_state s
GROUP BY s.room_id
ORDER BY count(s.room_id) DESC
LIMIT 20;
```
## Show top 20 larger tables by row count
```