17 lines
584 B
SQL
17 lines
584 B
SQL
SET enable_nereids_planner=TRUE;
|
|
SET enable_fallback_to_original_planner=FALSE;
|
|
SELECT
|
|
repo_name,
|
|
count() AS prs,
|
|
count(distinct actor_login) AS authors
|
|
FROM github_events
|
|
WHERE (event_type = 'PullRequestEvent') AND (action = 'opened') AND (actor_login IN
|
|
(
|
|
SELECT actor_login
|
|
FROM github_events
|
|
WHERE (event_type = 'PullRequestEvent') AND (action = 'opened') AND (repo_name IN ('yandex/ClickHouse', 'ClickHouse/ClickHouse'))
|
|
)) AND (lower(repo_name) NOT LIKE '%clickhouse%')
|
|
GROUP BY repo_name
|
|
ORDER BY authors DESC, prs DESC, length(repo_name) DESC
|
|
LIMIT 50
|