mirror of
https://github.com/LemmyNet/lemmy.git
synced 2024-12-12 05:54:51 +00:00
1c59f06fc8
- Fixes #232
11 lines
350 B
SQL
Vendored
11 lines
350 B
SQL
Vendored
drop view site_view;
|
|
|
|
create view site_view as
|
|
select *,
|
|
(select name from user_ u where s.creator_id = u.id) as creator_name,
|
|
(select count(*) from user_) as number_of_users,
|
|
(select count(*) from post) as number_of_posts,
|
|
(select count(*) from comment) as number_of_comments,
|
|
(select count(*) from community) as number_of_communities
|
|
from site s;
|