ClickHouse / ClickHouse/github-explorer

Fix for "Top commented issues for each of the top repositories"

Aperta Adatta ai principianti
#21 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub
Lingua principale
HTML
Stelle
180
Fork
19
Merge medio
3h 8m
PR unite (30g)
1

Descrizione

I think `sum` is wrong here. Each row contains the total number of stars.

```patch
---
index.html | 2 +-
queries.sql | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/index.html b/index.html
index a1b6343..03af266 100644
--- a/index.html
+++ b/index.html
@@ -3685,7 +3685,7 @@ LIMIT 50
max(comments),
argMax(authors, comments) AS authors,
argMax(number, comments) AS number,
- sum(stars) AS stars
+ any(stars) AS stars
FROM
(
SELECT *
diff --git a/queries.sql b/queries.sql
index 938e358..e7c13a6 100644
--- a/queries.sql
+++ b/queries.sql
@@ -671,7 +671,7 @@ SELECT
max(comments),
argMax(authors, comments) AS authors,
argMax(number, comments) AS number,
- sum(stars) AS stars
+ any(stars) AS stars
FROM
(
SELECT *
--
```

Guida per i contributori

Nessuna guida per i contributori indicizzata per questo repository

Direzione di ricerca

Inizia con l'aggregazione in queries.sql intorno alla riga 671 e confrontala con la query corrispondente in index.html intorno alla riga 3685. Controlla il risultato di top-commented-issues per confermare che il valore stars di ogni riga venga preservato anziché combinato tra le righe, quindi verifica che entrambe le copie producano lo stesso output.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
clickhouse, html, sql
Ambito
analytics, databases
Tipo di issue
Bug
Difficoltà
2/5
Tempo stimato
1-3 ore
Stato di attività
Ferma
Chiarezza
Specificata chiaramente
Idoneità per principianti
72/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.