From df1bea694fbed036ce6764404037bb19f99f3688 Mon Sep 17 00:00:00 2001 From: "Matteo Nastasi (mop)" Date: Wed, 26 Feb 2014 08:19:55 +0100 Subject: [PATCH] statadm.php: add constraint to count number of games with results <> 0 only --- web/briskin5/statadm.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/web/briskin5/statadm.php b/web/briskin5/statadm.php index f1c7bfc..4eb267b 100644 --- a/web/briskin5/statadm.php +++ b/web/briskin5/statadm.php @@ -341,7 +341,8 @@ function main_pgsql($curtime) WHERE m.tcode = %d AND m.code = g.mcode AND ( (u.type & (CAST (X'ff0000' as integer))) <> (CAST (X'800000' as integer)) ) AND g.tstamp > to_timestamp(%d) AND g.tstamp <= to_timestamp(%d) AND - p.ucode = u.code AND p.gcode = g.code + p.ucode = u.code AND p.gcode = g.code AND + p.pts != 0 GROUP BY u.code, u.login ORDER BY (float4(sum(p.pts)) * 100.0 ) / float4(count(p.pts)) DESC, count(p.pts) DESC", -- 2.17.1