ػѹѺ ­ҧ ʾ. ࢵ 4 (ҹ,к) [ ʾ.ҹ 1]
ç¹ ͧ ͧ ͧ Թ ͧᴧ
SELECT im_school.school_id AS s_id,im_school.school_name AS s_name, COUNT(*) AS NUB , COUNT(IF(im_team.award='ͧ',award,NULL)) AS gold_medal, COUNT(IF(im_team.award='Թ',award,NULL)) AS silver_medal, COUNT(IF(im_team.award='ͧᴧ',award,NULL)) AS bronze_medal, COUNT(IF(im_team.award='',award,NULL)) AS join_medal, COUNT(IF(im_team.rank='',rank,NULL)) AS winner, COUNT(IF(im_team.rank='ͧѹѺ ',rank,NULL)) AS two_rank, COUNT(IF(im_team.rank='ͧѹѺ ',rank,NULL)) AS three_rank FROM im_school,im_team WHERE im_school.province_id=28 AND im_school.area_type_id=2 AND im_school.zone_num=1 AND im_team.confirm_status=1 AND im_school.school_id=im_team.school_id GROUP BY im_team.school_id ORDER BY winner DESC, two_rank DESC, three_rank DESC, gold_medal DESC, silver_medal DESC,bronze_medal DESC,join_medal DESC, NUB DESC, s_name ASC
1 ǹҺԷ ѧԵ 49 32 20 101 92 24 5 4 121
2 24 17 17 58 54 25 14 11 93
3 ɮاҹ 24 13 16 53 48 25 11 8 84
4 óҪԷ ҹ 18 13 14 45 40 22 9 5 71
5 ʵͧǧԷҤ 17 17 14 48 46 26 9 9 81
6 ѧ ҹ 11 15 8 34 36 21 26 16 83
7 ش֡ҹ ҹ 7 8 4 19 21 19 11 13 51
8 ҪҷԹѴҵԷ 6 7 8 21 25 12 7 9 44
9 ջѧԷҾѲ(ѸѴѵɵ)㹾Ҫٻ 5 8 7 20 21 17 14 13 52
10 5 1 2 8 17 7 4 8 28
11 ҹ "ѹعպا" 4 3 5 12 13 21 10 12 44
12 ҸԵԷѧԵ 1 5 5 11 11 7 4 5 22
13 ૹ૿ͧ͡ 1 3 3 7 8 17 12 14 37
14 óѰ 1 3 1 5 6 2 3 4 11
15 عһЪä 1 2 1 4 2 4 7 1 13
16 ҸԵԷҪѯŧó 㹾кҪٻ 1 2 0 3 5 4 0 1 9
17 ҹѲ 1 1 1 3 4 6 3 4 13
18 Է "Ѳ ºا" 1 1 0 2 3 1 3 9 7
177 151 126 454 452 260 152 146 864